simp-beaker-helpers 1.7.2 → 1.7.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/Gemfile +6 -7
- data/lib/simp/beaker_helpers.rb +7 -0
- data/lib/simp/beaker_helpers/version.rb +1 -1
- data/spec/acceptance/enable_fips_spec.rb +16 -0
- data/spec/acceptance/fixture_modules_spec.rb +0 -7
- data/spec/acceptance/nodesets/default.yml +12 -13
- data/spec/acceptance/pki_tests_spec.rb +3 -13
- metadata +4 -8
- data/spec/acceptance/nodesets/centos-66-x64.yml +0 -22
- data/spec/acceptance/nodesets/centos-7-x64.yml +0 -22
- data/spec/acceptance/nodesets/centos-combined-x64.yaml +0 -24
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c7de1dfcac5f44c9466b55ae675bfe3191ecf512
|
4
|
+
data.tar.gz: fd4d1615265b83861e702fad89e3250051444e85
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e22ef74e3d2fdaa17a893441fa8efd24d26c7e5b00e402c7d2905d2cd2a69e6c555d94d76bb1e3423228b672ff2c0244e33215646d796299f4f464e1fa6a2460
|
7
|
+
data.tar.gz: 249acf36822fe694fd6468c03136ea221448c06b3739cb4ae7d189ee6bfbdabdeb18d4f63dc2f33d64b5231b64a8d3ffbc0f98e636f05ab83caa5587928b5656
|
data/Gemfile
CHANGED
@@ -1,9 +1,8 @@
|
|
1
|
-
#
|
2
|
-
#
|
3
|
-
#
|
4
|
-
|
5
|
-
|
6
|
-
gem_sources = ENV.key?('SIMP_GEM_SERVERS') ? ENV['SIMP_GEM_SERVERS'].split(/[, ]+/) : ['https://rubygems.org']
|
1
|
+
# ------------------------------------------------------------------------------
|
2
|
+
# NOTE: SIMP Puppet rake tasks support ruby 2.1.9
|
3
|
+
# ------------------------------------------------------------------------------
|
4
|
+
gem_sources = ENV.fetch('GEM_SERVERS','https://rubygems.org').split(/[, ]+/)
|
5
|
+
|
7
6
|
gem_sources.each { |gem_source| source gem_source }
|
8
7
|
|
9
8
|
# read dependencies in from the gemspec
|
@@ -19,5 +18,5 @@ group :system_tests do
|
|
19
18
|
gem 'beaker-rspec'
|
20
19
|
gem 'net-ssh'
|
21
20
|
gem 'puppetlabs_spec_helper'
|
22
|
-
gem 'puppet',
|
21
|
+
gem 'puppet', ENV.fetch('PUPPET_VERSION', '~> 4.0')
|
23
22
|
end
|
data/lib/simp/beaker_helpers.rb
CHANGED
@@ -173,6 +173,13 @@ module Simp::BeakerHelpers
|
|
173
173
|
# (last checked: 20150928)
|
174
174
|
package { ['kernel'] : ensure => 'latest' }
|
175
175
|
|
176
|
+
package { ['dracut-fips'] : ensure => 'latest' }
|
177
|
+
~>
|
178
|
+
exec { 'Always run dracut after installing dracut-fips':
|
179
|
+
command => '/usr/bin/dracut -f',
|
180
|
+
refreshonly => true
|
181
|
+
}
|
182
|
+
|
176
183
|
package { ['grubby'] : ensure => 'latest' }
|
177
184
|
~>
|
178
185
|
exec{ 'setup_fips':
|
@@ -0,0 +1,16 @@
|
|
1
|
+
require 'spec_helper_acceptance'
|
2
|
+
|
3
|
+
hosts.each do |host|
|
4
|
+
describe 'ensure FIPS mode matches ENV[BEAKER_fips]' do
|
5
|
+
context "on #{host}" do
|
6
|
+
it 'check /proc/sys/crypto/fips_enabled' do
|
7
|
+
stdout = on(host, 'cat /proc/sys/crypto/fips_enabled').stdout.strip
|
8
|
+
if ENV['BEAKER_fips'] == 'yes'
|
9
|
+
expect(stdout).to eq("1")
|
10
|
+
else
|
11
|
+
expect(stdout).to eq("0")
|
12
|
+
end
|
13
|
+
end
|
14
|
+
end
|
15
|
+
end
|
16
|
+
end
|
@@ -13,13 +13,6 @@ context 'after copy_fixture_modules_to( hosts )' do
|
|
13
13
|
end
|
14
14
|
end
|
15
15
|
|
16
|
-
describe "fact_on(master,'root_home', {:puppet => nil})" do
|
17
|
-
it 'should return value of `root_home`' do
|
18
|
-
puts fact = fact_on(master, 'root_home', {:puppet => nil} )
|
19
|
-
expect( fact ).to eq '/root'
|
20
|
-
end
|
21
|
-
end
|
22
|
-
|
23
16
|
describe "pfact_on(master,'root_home')" do
|
24
17
|
it 'should return value of `root_home`' do
|
25
18
|
puts fact = pfact_on(master, 'root_home')
|
@@ -1,23 +1,22 @@
|
|
1
1
|
HOSTS:
|
2
|
-
server:
|
2
|
+
server-el7:
|
3
3
|
roles:
|
4
4
|
- server
|
5
5
|
- default
|
6
6
|
- master
|
7
|
+
- el7
|
7
8
|
platform: el-7-x86_64
|
8
|
-
box:
|
9
|
-
box_url: https://vagrantcloud.com/puppetlabs/boxes/centos-7.0-64-nocm
|
9
|
+
box: centos/7
|
10
10
|
hypervisor: vagrant
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
11
|
+
|
12
|
+
server-el6:
|
13
|
+
roles:
|
14
|
+
- el6
|
15
|
+
platform: el-6-x86_64
|
16
|
+
box: centos/6
|
17
|
+
hypervisor: vagrant
|
18
|
+
|
19
19
|
CONFIG:
|
20
20
|
log_level: verbose
|
21
|
-
type:
|
21
|
+
type: aio
|
22
22
|
vagrant_memsize: 256
|
23
|
-
## vb_gui: true
|
@@ -28,8 +28,8 @@ context 'PKI operations' do
|
|
28
28
|
end
|
29
29
|
|
30
30
|
describe 'a Fake CA under /root' do
|
31
|
-
|
32
|
-
run_fake_pki_ca_on( master, hosts,
|
31
|
+
tmp_keydist_dir = Dir.mktmpdir 'simp-beaker-helpers__pki-tests'
|
32
|
+
run_fake_pki_ca_on( master, hosts, tmp_keydist_dir )
|
33
33
|
|
34
34
|
it 'should create /root/pki' do
|
35
35
|
on(master, 'test -d /root/pki')
|
@@ -37,16 +37,10 @@ context 'PKI operations' do
|
|
37
37
|
|
38
38
|
it_behaves_like 'a correctly copied keydist/ tree', '/root/pki/keydist'
|
39
39
|
|
40
|
-
### TODO: fix scoping issues
|
41
|
-
### it "copied keydist back to local directory '#{@tmp_keydist_dir}'" do
|
42
|
-
### require 'pry'; binding.pry
|
43
|
-
### expect( File.directory? @tmp_keydist_dir ).to be_truthy
|
44
|
-
### end
|
45
40
|
end
|
46
41
|
|
47
|
-
|
48
42
|
describe 'after copy_keydist_to' do
|
49
|
-
test_dir = '/etc/
|
43
|
+
test_dir = '/etc/puppetlabs/code/environments/production/modules/pki/files/keydist'
|
50
44
|
copy_keydist_to(master)
|
51
45
|
it_behaves_like 'a correctly copied keydist/ tree', test_dir
|
52
46
|
end
|
@@ -57,9 +51,5 @@ context 'PKI operations' do
|
|
57
51
|
it_behaves_like 'a correctly copied keydist/ tree', test_dir
|
58
52
|
end
|
59
53
|
|
60
|
-
after( :all ) do
|
61
|
-
FileUtils.remove_entry_secure( @tmp_keydist_dir )
|
62
|
-
end
|
63
54
|
end
|
64
|
-
|
65
55
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: simp-beaker-helpers
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.7.
|
4
|
+
version: 1.7.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Chris Tessmer
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2017-
|
12
|
+
date: 2017-06-16 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: beaker
|
@@ -63,10 +63,8 @@ files:
|
|
63
63
|
- lib/simp/beaker_helpers/version.rb
|
64
64
|
- lib/simp/rake/beaker.rb
|
65
65
|
- simp-beaker-helpers.gemspec
|
66
|
+
- spec/acceptance/enable_fips_spec.rb
|
66
67
|
- spec/acceptance/fixture_modules_spec.rb
|
67
|
-
- spec/acceptance/nodesets/centos-66-x64.yml
|
68
|
-
- spec/acceptance/nodesets/centos-7-x64.yml
|
69
|
-
- spec/acceptance/nodesets/centos-combined-x64.yaml
|
70
68
|
- spec/acceptance/nodesets/default.yml
|
71
69
|
- spec/acceptance/pki_tests_spec.rb
|
72
70
|
- spec/acceptance/set_hieradata_on_spec.rb
|
@@ -98,10 +96,8 @@ signing_key:
|
|
98
96
|
specification_version: 4
|
99
97
|
summary: beaker helper methods for SIMP
|
100
98
|
test_files:
|
99
|
+
- spec/acceptance/enable_fips_spec.rb
|
101
100
|
- spec/acceptance/fixture_modules_spec.rb
|
102
|
-
- spec/acceptance/nodesets/centos-66-x64.yml
|
103
|
-
- spec/acceptance/nodesets/centos-7-x64.yml
|
104
|
-
- spec/acceptance/nodesets/centos-combined-x64.yaml
|
105
101
|
- spec/acceptance/nodesets/default.yml
|
106
102
|
- spec/acceptance/pki_tests_spec.rb
|
107
103
|
- spec/acceptance/set_hieradata_on_spec.rb
|
@@ -1,22 +0,0 @@
|
|
1
|
-
HOSTS:
|
2
|
-
server:
|
3
|
-
roles:
|
4
|
-
- default
|
5
|
-
- master
|
6
|
-
- server
|
7
|
-
platform: el-6-x86_64
|
8
|
-
box: puppetlabs/centos-6.6-64-nocm
|
9
|
-
box_url: https://vagrantcloud.com/puppetlabs/boxes/centos-6.6-64-nocm
|
10
|
-
hypervisor: vagrant
|
11
|
-
client:
|
12
|
-
roles:
|
13
|
-
- agent
|
14
|
-
- client
|
15
|
-
platform: el-6-x86_64
|
16
|
-
box: puppetlabs/centos-6.6-64-nocm
|
17
|
-
box_url: https://vagrantcloud.com/puppetlabs/boxes/centos-6.6-64-nocm
|
18
|
-
hypervisor: vagrant
|
19
|
-
CONFIG:
|
20
|
-
log_level: verbose
|
21
|
-
type: foss
|
22
|
-
vagrant_memsize: 256
|
@@ -1,22 +0,0 @@
|
|
1
|
-
HOSTS:
|
2
|
-
server:
|
3
|
-
roles:
|
4
|
-
- server
|
5
|
-
- default
|
6
|
-
- master
|
7
|
-
platform: el-7-x86_64
|
8
|
-
box: puppetlabs/centos-7.0-64-nocm
|
9
|
-
box_url: https://vagrantcloud.com/puppetlabs/boxes/centos-7.0-64-nocm
|
10
|
-
hypervisor: vagrant
|
11
|
-
client:
|
12
|
-
roles:
|
13
|
-
- client
|
14
|
-
- agent
|
15
|
-
platform: el-7-x86_64
|
16
|
-
box: puppetlabs/centos-7.0-64-nocm
|
17
|
-
box_url: https://vagrantcloud.com/puppetlabs/boxes/centos-7.0-64-nocm
|
18
|
-
hypervisor: vagrant
|
19
|
-
CONFIG:
|
20
|
-
log_level: verbose
|
21
|
-
type: foss
|
22
|
-
vagrant_memsize: 256
|
@@ -1,24 +0,0 @@
|
|
1
|
-
# This nodeset spins up a simple one-host test VM for both EL6 and EL7
|
2
|
-
HOSTS:
|
3
|
-
centos-7:
|
4
|
-
roles:
|
5
|
-
- server
|
6
|
-
- default
|
7
|
-
- master
|
8
|
-
platform: el-7-x86_64
|
9
|
-
box: puppetlabs/centos-7.0-64-nocm
|
10
|
-
box_url: https://vagrantcloud.com/puppetlabs/boxes/centos-7.0-64-nocm
|
11
|
-
hypervisor: vagrant
|
12
|
-
centos-6:
|
13
|
-
roles:
|
14
|
-
- agent
|
15
|
-
- client
|
16
|
-
platform: el-6-x86_64
|
17
|
-
box: puppetlabs/centos-6.6-64-nocm
|
18
|
-
box_url: https://vagrantcloud.com/puppetlabs/boxes/centos-6.6-64-nocm
|
19
|
-
hypervisor: vagrant
|
20
|
-
CONFIG:
|
21
|
-
log_level: verbose
|
22
|
-
type: foss
|
23
|
-
vagrant_memsize: 256
|
24
|
-
## vb_gui: true
|