Class: Composer::Deploy::Stack
- Inherits:
-
Object
- Object
- Composer::Deploy::Stack
- Defined in:
- lib/composer/deploy/stack.rb
Instance Method Summary collapse
- #create(args) ⇒ Object
-
#initialize(args) ⇒ Stack
constructor
A new instance of Stack.
Constructor Details
#initialize(args) ⇒ Stack
Returns a new instance of Stack.
4 5 6 |
# File 'lib/composer/deploy/stack.rb', line 4 def initialize(args) @config = args[:config] end |
Instance Method Details
#create(args) ⇒ Object
8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 |
# File 'lib/composer/deploy/stack.rb', line 8 def create(args) directory = args[:directory] key = args[:key] name = args[:name] secret = args[:secret] app_version = 'v1.0.0' chef_version = 'v1.0.0' environment_secret = 'password' environment = 'default' template = "#{directory}/cloud-formation-templates/examples/classic/asg.json" puts "" puts "Deploy Example Stack:" puts "" puts "simple_deploy create -e #{environment} -n #{name} -t #{template} -a AppName=#{name} -a EnvironmentSecret=#{environment_secret} -a KeyName=#{key} -a AppSecret=#{secret} -a ChefRepoSecret=#{secret} -a app=#{app_version} -a chef_repo=#{chef_version} -a app_domain=#{name}-app -a chef_repo_domain=#{name}-chef-repo -a app_bucket_prefix=#{name} -a chef_repo_bucket_prefix=#{name} -a chef_repo_encrypted=true -a app_encrypted=true" end |