lib/simple_deploy/cli/deploy.rb in simple_deploy-0.7.2 vs lib/simple_deploy/cli/deploy.rb in simple_deploy-0.7.3
- old
+ new
@@ -52,26 +52,27 @@
end
valid_options? :provided => @opts,
:required => [:environment, :name]
+ SimpleDeploy.create_config @opts[:environment]
+ logger = SimpleDeploy.logger @opts[:log_level]
+
new_attributes = parse_attributes :attributes => @opts[:attributes]
@opts[:name].each do |name|
notifier = Notifier.new :stack_name => name,
- :environment => @opts[:environment],
- :logger => logger
+ :environment => @opts[:environment]
- stack = Stack.new :environment => @opts[:environment],
- :name => name,
- :logger => logger,
- :internal => @opts[:internal]
+ stack = Stack.new :name => name,
+ :environment => @opts[:environment],
+ :internal => @opts[:internal]
proceed = true
if new_attributes.any?
- rescue_stackster_exceptions_and_exit do
+ rescue_exceptions_and_exit do
proceed = stack.update :force => @opts[:force],
:attributes => new_attributes
end
end
@@ -92,13 +93,9 @@
logger.error "Update of #{name} did not complete succesfully."
exit 1
end
end
- end
-
- def logger
- @logger ||= SimpleDeployLogger.new :log_level => @opts[:log_level]
end
def command_summary
'Execute deployment on given stack(s)'
end