lib/simple_deploy/cli/update.rb in simple_deploy-0.7.3 vs lib/simple_deploy/cli/update.rb in simple_deploy-0.7.4

- old
+ new

@@ -23,10 +23,11 @@ opt :force, "Force an update to proceed" opt :log_level, "Log level: debug, info, warn, error", :type => :string, :default => 'info' opt :name, "Stack name(s) of stack to deploy", :type => :string, :multi => true + opt :template, "Path to a new template file", :type => :string end valid_options? :provided => @opts, :required => [:environment, :name] @@ -37,11 +38,17 @@ @opts[:name].each do |name| stack = Stack.new :name => name, :environment => @opts[:environment] + if @opts[:template] + template_body = IO.read @opts[:template] + end + rescue_exceptions_and_exit do - stack.update :force => @opts[:force], :attributes => attributes + stack.update :force => @opts[:force], + :template_body => template_body, + :attributes => attributes end end end def command_summary