lib/aerosol.rb in aerosol-1.8.0 vs lib/aerosol.rb in aerosol-1.9.0
- old
+ new
@@ -11,10 +11,11 @@
module Aerosol
require 'aerosol/aws'
require 'aerosol/util'
require 'aerosol/aws_model'
require 'aerosol/launch_configuration'
+ require 'aerosol/launch_template'
require 'aerosol/auto_scaling'
require 'aerosol/instance'
require 'aerosol/connection'
require 'aerosol/deploy'
require 'aerosol/env'
@@ -59,19 +60,21 @@
def setup
{
:auto_scalings => Aerosol::AutoScaling.instances,
:deploys => Aerosol::Deploy.instances,
:launch_configurations => Aerosol::LaunchConfiguration.instances,
+ :launch_templates => Aerosol::LaunchTemplate.instances,
:sshs => Aerosol::Connection.instances,
:envs => Aerosol::Env.instances
}
end
{
:auto_scaling => Aerosol::AutoScaling,
:deploy => Aerosol::Deploy,
:launch_configuration => Aerosol::LaunchConfiguration,
+ :launch_template => Aerosol::LaunchTemplate,
:ssh => Aerosol::Connection,
:env => Aerosol::Env
}.each do |method, klass|
define_method(method) do |sym, &block|
if block.nil?
@@ -80,18 +83,18 @@
klass.new!(:name => sym, &block)
end
end
end
- [:auto_scalings, :deploys, :launch_configurations, :sshs, :envs].each do |method|
+ [:auto_scalings, :deploys, :launch_configurations, :launch_templates, :sshs, :envs].each do |method|
define_method(method) do
inst[method]
end
end
module_function :inst, :load_inst, :setup, :load_file, :load_file=,
- :auto_scaling, :launch_configuration, :deploy, :ssh, :git_sha,
- :auto_scalings, :launch_configurations, :deploys, :sshs,
+ :auto_scaling, :launch_configuration, :launch_template, :deploy, :ssh, :git_sha,
+ :auto_scalings, :launch_configurations, :launch_templates, :deploys, :sshs,
:namespace, :env, :envs, :region
end
require 'aerosol/runner'
require 'aerosol/rake_task'