Class: Opsicle::Deploy
- Inherits:
-
Object
- Object
- Opsicle::Deploy
- Includes:
- DeployHelper
- Defined in:
- lib/opsicle/commands/deploy.rb
Instance Attribute Summary collapse
-
#client ⇒ Object
readonly
Returns the value of attribute client.
Instance Method Summary collapse
- #execute(options = { monitor: true }) ⇒ Object
-
#initialize(environment) ⇒ Deploy
constructor
A new instance of Deploy.
Methods included from DeployHelper
#launch_stack_monitor, #open_deploy
Constructor Details
Instance Attribute Details
#client ⇒ Object (readonly)
Returns the value of attribute client.
6 7 8 |
# File 'lib/opsicle/commands/deploy.rb', line 6 def client @client end |
Instance Method Details
#execute(options = { monitor: true }) ⇒ Object
13 14 15 16 17 18 19 20 21 22 23 24 25 |
# File 'lib/opsicle/commands/deploy.rb', line 13 def execute(={ monitor: true }) Output.say "Starting OpsWorks deploy..." #so this is how to format the command arguments: #http://docs.aws.amazon.com/AWSRubySDK/latest/AWS/OpsWorks/Client.html#create_deployment-instance_method command_args = {} command_args["migrate"] = [[:migrate].to_s] if [:migrate] command_opts = {} command_opts["custom_json"] = .delete(:json) if [:json] response = client.run_command('deploy', command_args, command_opts) launch_stack_monitor(response, ) end |