ec2launcher 1.3.8 → 1.3.9

Sign up to get free protection for your applications and to get access to all the features.
data/CHANGELOG.md CHANGED
@@ -1,3 +1,7 @@
1
+ ## 1.3.9
2
+
3
+ * More cleanup to terminator code.
4
+
1
5
  ## 1.3.8
2
6
 
3
7
  * Make terminator code more threadsafe.
data/bin/ec2launcher CHANGED
@@ -27,7 +27,7 @@ if opt_parser.command == "init"
27
27
 
28
28
  puts "Successfully created #{opt_parser.location}"
29
29
  elsif opt_parser.command =~ /^term/
30
- terminator = EC2Launcher::Terminator.new
30
+ terminator = EC2Launcher::Terminator.new(opt_parser.options.directory, opt_parser.options.environ)
31
31
  terminator.terminate(opt_parser.hostname, opt_parser.options.access_key, opt_parser.options.secret_key)
32
32
  elsif opt_parser.command == "launch"
33
33
  launcher = EC2Launcher::Launcher.new
@@ -14,7 +14,7 @@ module EC2Launcher
14
14
  include AWSInitializer
15
15
  include BackoffRunner
16
16
 
17
- def initialize()
17
+ def initialize(config_directory, environment_name)
18
18
  @log = Logger.new 'ec2launcher'
19
19
  log_output = Outputter.stdout
20
20
  log_output.formatter = PatternFormatter.new :pattern => "%m"
@@ -23,7 +23,7 @@ module EC2Launcher
23
23
  ##############################
24
24
  # Load configuration data
25
25
  ##############################
26
- config_wrapper = ConfigWrapper.new(options.directory)
26
+ config_wrapper = ConfigWrapper.new(config_directory)
27
27
 
28
28
  @config = config_wrapper.config
29
29
  @environments = config_wrapper.environments
@@ -31,11 +31,11 @@ module EC2Launcher
31
31
  ##############################
32
32
  # ENVIRONMENT
33
33
  ##############################
34
- unless @environments.has_key? options.environ
35
- @log.fatal "Environment not found: #{options.environ}"
34
+ unless @environments.has_key? environment_name
35
+ @log.fatal "Environment not found: #{environment_name}"
36
36
  exit 2
37
37
  end
38
- @environment = @environments[options.environ]
38
+ @environment = @environments[environment_name]
39
39
  end
40
40
 
41
41
  # Terminates a given server instance.
@@ -2,5 +2,5 @@
2
2
  # Copyright (c) 2012 Sean Laurent
3
3
  #
4
4
  module EC2Launcher
5
- VERSION = "1.3.8"
5
+ VERSION = "1.3.9"
6
6
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ec2launcher
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.3.8
4
+ version: 1.3.9
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2012-10-18 00:00:00.000000000 Z
12
+ date: 2012-10-19 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: aws-sdk