elasticity 6.0.7 → 6.0.8

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: f8acfedb244b21d3b8ab10c2c78b33006f15b9c9
4
- data.tar.gz: 72978cfbb6598c283771630159f2203b0d2722f8
3
+ metadata.gz: 3cd50c2b68572e1a5e546d3ff07e49e040b60a92
4
+ data.tar.gz: cfda4f23570cb4206835b9e4e6366807d7ab2f4c
5
5
  SHA512:
6
- metadata.gz: cb3ade000c41023d37fba15f48df3be25f2d02ab7a62ee1e75c3fdc576a88d7cde639b8cff8b4144ba2b9d31ce281f6e0c55b3aae1573443e4b890d8b1db3ad6
7
- data.tar.gz: 344e4daeb4d74e6fdefdc74a8ad6c05a3a68fa5c3b623197c5b0935a03081bb2291ffaf9da307c88cfb243228a360c6190831d0d2846130cbcfe14af48cc2723
6
+ metadata.gz: c61bae14a944d248c96cf45bb522de9bf611bcad24599d158fed27003f2d1c164afb58451fba87c62e55b68fc10f05ab0dc28df49b1b9fc0ca9b6433aaedb231
7
+ data.tar.gz: 25c6be356bf71593510bca93f8f327c8f5162ade323d15bf4fca7e68c5ef9a2017050de7307add76a930808e4f8c3706b9327a267356029df4d5aaa21b54d978
data/HISTORY.md CHANGED
@@ -1,8 +1,12 @@
1
- ## 6.0.7 - February 29, 2016
1
+ ## 6.0.8 - February 22, 2016
2
+
3
+ - Including PR [#126](https://github.com/rslifka/elasticity/pull/126) - "Add support for additional security groups". Thank you [@alistair](https://github.com/alistair)!
4
+
5
+ ## 6.0.7 - February 1, 2016
2
6
 
3
7
  - Including PR [#125](https://github.com/rslifka/elasticity/pull/125) - "AMI 4.x support". Thank you [@fblundun](https://github.com/fblundun)!
4
8
 
5
- ## 6.0.6 - February 29, 2016
9
+ ## 6.0.6 - January 29, 2016
6
10
 
7
11
  - Including PR [#120](https://github.com/rslifka/elasticity/pull/120) - "EMR Applications and support for release_label". Thank you [@robert2d](https://github.com/robert2d)!
8
12
 
data/README.md CHANGED
@@ -132,6 +132,8 @@ jobflow.instance_count = 2
132
132
  jobflow.master_instance_type = 'm1.small'
133
133
  jobflow.slave_instance_type = 'm1.small'
134
134
  jobflow.additonal_info = 'additonal info'
135
+ jobflow.additional_master_security_groups = ['sg-1111', 'sg-2222']
136
+ jobflow.additional_slave_security_groups = ['sg-1111', 'sg-2222']
135
137
  ```
136
138
 
137
139
  ### EMR Applications (optional needs release_label >= 4.0.0)
@@ -29,6 +29,8 @@ module Elasticity
29
29
  attr_accessor :jobflow_id
30
30
  attr_accessor :aws_applications
31
31
  attr_accessor :additional_info
32
+ attr_accessor :additional_master_security_groups
33
+ attr_accessor :additional_slave_security_groups
32
34
 
33
35
  def initialize
34
36
  @action_on_failure = 'TERMINATE_JOB_FLOW'
@@ -246,6 +248,8 @@ module Elasticity
246
248
  preamble[:instances].delete(:placement)
247
249
  end
248
250
  preamble[:instances].merge!(:ec2_key_name => @ec2_key_name) if @ec2_key_name
251
+ preamble[:instances].merge!(:additional_master_security_groups => @additional_master_security_groups) if @additional_master_security_groups
252
+ preamble[:instances].merge!(:additional_slave_security_groups => @additional_slave_security_groups) if @additional_slave_security_groups
249
253
  preamble
250
254
  end
251
255
 
@@ -1,3 +1,3 @@
1
1
  module Elasticity
2
- VERSION = '6.0.7'
2
+ VERSION = '6.0.8'
3
3
  end
@@ -123,7 +123,7 @@ describe Elasticity::AwsRequestV4 do
123
123
 
124
124
  describe '.aws_v4_signature' do
125
125
  it 'should create the proper signature' do
126
- subject.send(:aws_v4_signature).should == '2012c7d0d1fecd99b023d2a81a5930300436e4739f274301932941506e8fc9bf'
126
+ subject.send(:aws_v4_signature).should == '8cd99127235ec8f7c9304ad55d1ef702c556d1d5169dd2d224e6cf86fe179f1e'
127
127
  end
128
128
  end
129
129
 
@@ -26,6 +26,8 @@ describe Elasticity::JobFlow do
26
26
  expect(subject.service_role).to eql(nil)
27
27
  expect(subject.additional_info).to eql(nil)
28
28
  expect(subject.jobflow_id).to eql(nil)
29
+ expect(subject.additional_master_security_groups).to eql(nil)
30
+ expect(subject.additional_slave_security_groups).to eql(nil)
29
31
  end
30
32
  end
31
33
 
@@ -618,6 +620,19 @@ describe Elasticity::JobFlow do
618
620
  end
619
621
  end
620
622
 
623
+ context 'when additional master security groups is provided' do
624
+ it 'should include it in the preamble' do
625
+ subject.additional_master_security_groups = ['group1', 'group2']
626
+ subject.send(:jobflow_preamble)[:instances].should be_a_hash_including({:additional_master_security_groups => ['group1', 'group2']})
627
+ end
628
+ end
629
+
630
+ context 'when additional slave security groups is provided' do
631
+ it 'should include it in the preamble' do
632
+ subject.additional_slave_security_groups = ['group1', 'group2']
633
+ subject.send(:jobflow_preamble)[:instances].should be_a_hash_including({:additional_slave_security_groups => ['group1', 'group2']})
634
+ end
635
+ end
621
636
  end
622
637
 
623
638
  describe '#run' do
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: elasticity
3
3
  version: !ruby/object:Gem::Version
4
- version: 6.0.7
4
+ version: 6.0.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Robert Slifka
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-02-01 00:00:00.000000000 Z
11
+ date: 2016-02-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rest-client