ami_spec 1.1.0 → 1.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.ruby-version +1 -1
- data/.travis.yml +4 -3
- data/ami_spec.gemspec +7 -5
- data/bin/ami_spec +0 -1
- data/lib/ami_spec.rb +3 -3
- data/lib/ami_spec/aws_instance.rb +1 -1
- data/lib/ami_spec/server_spec.rb +5 -1
- data/lib/ami_spec/version.rb +1 -1
- metadata +20 -20
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6bf865c78d589bc86d5e434dcb49d3ae8dcf301b1c07181d6a9d2f569ccd284e
|
4
|
+
data.tar.gz: ace2b925ce79810075177b8e90113b84fc15f574be9c0cd782aa0ec90536c643
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4263f8621665309d2de4859291b286a9bd3b5d5545ac47df20a1bbb56c589ae93585b55418121545afffdbf592c45a7594d171d403d1e94adde1bb0fe7357e73
|
7
|
+
data.tar.gz: 8327271a25293d9cb08f1b9ae0e56983a39ac8d673acb1e7186183faf99d561c827a372251ba70e10100f80c287a6bf2a2578604e829611842bd76bbffaeec45
|
data/.ruby-version
CHANGED
@@ -1 +1 @@
|
|
1
|
-
|
1
|
+
2.5.1
|
data/.travis.yml
CHANGED
data/ami_spec.gemspec
CHANGED
@@ -17,11 +17,13 @@ Gem::Specification.new do |gem|
|
|
17
17
|
gem.test_files = gem.files.grep(%r{^(test|spec|features)/})
|
18
18
|
gem.require_paths = ['lib']
|
19
19
|
|
20
|
-
gem.add_dependency 'aws-sdk', '~>
|
21
|
-
gem.
|
22
|
-
gem.add_dependency 'serverspec'
|
20
|
+
gem.add_dependency 'aws-sdk-ec2', '~> 1'
|
21
|
+
gem.add_development_dependency 'rake'
|
22
|
+
gem.add_dependency 'serverspec', '~> 2'
|
23
23
|
gem.add_dependency 'specinfra', '>= 2.45'
|
24
|
-
gem.add_dependency '
|
24
|
+
gem.add_dependency 'optimist', '~> 3'
|
25
25
|
gem.add_dependency 'hashie'
|
26
|
-
gem.add_dependency 'net-ssh', '
|
26
|
+
gem.add_dependency 'net-ssh', '~> 5'
|
27
|
+
|
28
|
+
gem.required_ruby_version = '>= 2.2.6'
|
27
29
|
end
|
data/bin/ami_spec
CHANGED
data/lib/ami_spec.rb
CHANGED
@@ -4,7 +4,7 @@ require 'ami_spec/server_spec'
|
|
4
4
|
require 'ami_spec/server_spec_options'
|
5
5
|
require 'ami_spec/wait_for_ssh'
|
6
6
|
require 'ami_spec/wait_for_rc'
|
7
|
-
require '
|
7
|
+
require 'optimist'
|
8
8
|
|
9
9
|
module AmiSpec
|
10
10
|
class InstanceConnectionTimeout < StandardError; end
|
@@ -83,7 +83,7 @@ module AmiSpec
|
|
83
83
|
private_class_method :stop_instances
|
84
84
|
|
85
85
|
def self.invoke
|
86
|
-
options =
|
86
|
+
options = Optimist::options do
|
87
87
|
opt :role, "The role to test, this should map to a directory in the spec folder", type: :string
|
88
88
|
opt :ami, "The ami ID to run tests against", type: :string
|
89
89
|
opt :role_ami_file, "A file containing comma separated roles and amis. i.e.\nweb_server,ami-id.",
|
@@ -96,7 +96,7 @@ module AmiSpec
|
|
96
96
|
opt :aws_region, "The AWS region, defaults to AWS_DEFAULT_REGION environment variable", type: :string
|
97
97
|
opt :aws_instance_type, "The ec2 instance type, defaults to t2.micro", type: :string, default: 't2.micro'
|
98
98
|
opt :aws_security_groups, "Security groups to associate to the launched instances. May be specified multiple times",
|
99
|
-
type: :
|
99
|
+
type: :string, default: nil, multi: true
|
100
100
|
opt :aws_public_ip, "Launch instances with a public IP"
|
101
101
|
opt :ssh_retries, "The number of times we should try sshing to the ec2 instance before giving up. Defaults to 30",
|
102
102
|
type: :int, default: 30
|
data/lib/ami_spec/server_spec.rb
CHANGED
@@ -28,7 +28,11 @@ module AmiSpec
|
|
28
28
|
end
|
29
29
|
|
30
30
|
$LOAD_PATH.unshift(@spec) unless $LOAD_PATH.include?(@spec)
|
31
|
-
|
31
|
+
begin
|
32
|
+
require File.join(@spec, 'spec_helper')
|
33
|
+
rescue LoadError
|
34
|
+
puts 'Spec Helper does not exist. Skipping!'
|
35
|
+
end
|
32
36
|
|
33
37
|
set :backend, :ssh
|
34
38
|
set :host, @ip
|
data/lib/ami_spec/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ami_spec
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Patrick Robinson
|
@@ -9,22 +9,22 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date:
|
12
|
+
date: 2019-02-18 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
|
-
name: aws-sdk
|
15
|
+
name: aws-sdk-ec2
|
16
16
|
requirement: !ruby/object:Gem::Requirement
|
17
17
|
requirements:
|
18
18
|
- - "~>"
|
19
19
|
- !ruby/object:Gem::Version
|
20
|
-
version: '
|
20
|
+
version: '1'
|
21
21
|
type: :runtime
|
22
22
|
prerelease: false
|
23
23
|
version_requirements: !ruby/object:Gem::Requirement
|
24
24
|
requirements:
|
25
25
|
- - "~>"
|
26
26
|
- !ruby/object:Gem::Version
|
27
|
-
version: '
|
27
|
+
version: '1'
|
28
28
|
- !ruby/object:Gem::Dependency
|
29
29
|
name: rake
|
30
30
|
requirement: !ruby/object:Gem::Requirement
|
@@ -32,7 +32,7 @@ dependencies:
|
|
32
32
|
- - ">="
|
33
33
|
- !ruby/object:Gem::Version
|
34
34
|
version: '0'
|
35
|
-
type: :
|
35
|
+
type: :development
|
36
36
|
prerelease: false
|
37
37
|
version_requirements: !ruby/object:Gem::Requirement
|
38
38
|
requirements:
|
@@ -43,16 +43,16 @@ dependencies:
|
|
43
43
|
name: serverspec
|
44
44
|
requirement: !ruby/object:Gem::Requirement
|
45
45
|
requirements:
|
46
|
-
- - "
|
46
|
+
- - "~>"
|
47
47
|
- !ruby/object:Gem::Version
|
48
|
-
version: '
|
48
|
+
version: '2'
|
49
49
|
type: :runtime
|
50
50
|
prerelease: false
|
51
51
|
version_requirements: !ruby/object:Gem::Requirement
|
52
52
|
requirements:
|
53
|
-
- - "
|
53
|
+
- - "~>"
|
54
54
|
- !ruby/object:Gem::Version
|
55
|
-
version: '
|
55
|
+
version: '2'
|
56
56
|
- !ruby/object:Gem::Dependency
|
57
57
|
name: specinfra
|
58
58
|
requirement: !ruby/object:Gem::Requirement
|
@@ -68,19 +68,19 @@ dependencies:
|
|
68
68
|
- !ruby/object:Gem::Version
|
69
69
|
version: '2.45'
|
70
70
|
- !ruby/object:Gem::Dependency
|
71
|
-
name:
|
71
|
+
name: optimist
|
72
72
|
requirement: !ruby/object:Gem::Requirement
|
73
73
|
requirements:
|
74
|
-
- - "
|
74
|
+
- - "~>"
|
75
75
|
- !ruby/object:Gem::Version
|
76
|
-
version: '
|
76
|
+
version: '3'
|
77
77
|
type: :runtime
|
78
78
|
prerelease: false
|
79
79
|
version_requirements: !ruby/object:Gem::Requirement
|
80
80
|
requirements:
|
81
|
-
- - "
|
81
|
+
- - "~>"
|
82
82
|
- !ruby/object:Gem::Version
|
83
|
-
version: '
|
83
|
+
version: '3'
|
84
84
|
- !ruby/object:Gem::Dependency
|
85
85
|
name: hashie
|
86
86
|
requirement: !ruby/object:Gem::Requirement
|
@@ -99,16 +99,16 @@ dependencies:
|
|
99
99
|
name: net-ssh
|
100
100
|
requirement: !ruby/object:Gem::Requirement
|
101
101
|
requirements:
|
102
|
-
- - "
|
102
|
+
- - "~>"
|
103
103
|
- !ruby/object:Gem::Version
|
104
|
-
version: '
|
104
|
+
version: '5'
|
105
105
|
type: :runtime
|
106
106
|
prerelease: false
|
107
107
|
version_requirements: !ruby/object:Gem::Requirement
|
108
108
|
requirements:
|
109
|
-
- - "
|
109
|
+
- - "~>"
|
110
110
|
- !ruby/object:Gem::Version
|
111
|
-
version: '
|
111
|
+
version: '5'
|
112
112
|
description: Acceptance testing your AMIs
|
113
113
|
email: []
|
114
114
|
executables:
|
@@ -158,7 +158,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
158
158
|
requirements:
|
159
159
|
- - ">="
|
160
160
|
- !ruby/object:Gem::Version
|
161
|
-
version:
|
161
|
+
version: 2.2.6
|
162
162
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
163
163
|
requirements:
|
164
164
|
- - ">="
|