diff --git a/.travis.yml b/.travis.yml index fa92d5a..16f9923 100644 --- a/.travis.yml +++ b/.travis.yml @@ -25,24 +25,28 @@ env: # - INSTANCE: fedora-30-develop-py3 # - INSTANCE: opensuse-leap-15-develop-py3 # - INSTANCE: amazonlinux-2-develop-py2 + # - INSTANCE: arch-base-latest-develop-py2 # - INSTANCE: debian-9-2019-2-py3 - - INSTANCE: ubuntu-1804-2019-2-py3 + - INSTANCE: prod-server-ubuntu-1804-2019-2-py3 # - INSTANCE: centos-7-2019-2-py3 - # - INSTANCE: fedora-30-2019-2-py3 + - INSTANCE: prod-server-fedora-30-2019-2-py3 # - INSTANCE: opensuse-leap-15-2019-2-py3 - - INSTANCE: amazonlinux-2-2019-2-py2 + - INSTANCE: prod-server-amazonlinux-2-2019-2-py2 + # - INSTANCE: arch-base-latest-2019-2-py2 # - INSTANCE: debian-9-2018-3-py2 # - INSTANCE: ubuntu-1604-2018-3-py2 - # - INSTANCE: centos-7-2018-3-py2 - - INSTANCE: fedora-29-2018-3-py2 - - INSTANCE: opensuse-leap-15-2018-3-py2 + - INSTANCE: prod-server-centos-7-2018-3-py2 + # - INSTANCE: fedora-29-2018-3-py2 + - INSTANCE: prod-server-opensuse-leap-15-2018-3-py2 # - INSTANCE: amazonlinux-2-2018-3-py2 + # - INSTANCE: arch-base-latest-2018-3-py2 # - INSTANCE: debian-8-2017-7-py2 # - INSTANCE: ubuntu-1604-2017-7-py2 - - INSTANCE: centos-6-2017-7-py2 + # - INSTANCE: centos-6-2017-7-py2 # - INSTANCE: fedora-29-2017-7-py2 # - INSTANCE: opensuse-leap-15-2017-7-py2 # - INSTANCE: amazonlinux-2-2017-7-py2 + - INSTANCE: prod-server-arch-base-latest-2017-7-py2 script: - bin/kitchen verify ${INSTANCE} diff --git a/Gemfile b/Gemfile index 3b36de3..2c33118 100644 --- a/Gemfile +++ b/Gemfile @@ -3,4 +3,5 @@ source "https://rubygems.org" gem 'kitchen-docker', '>= 2.9' gem 'kitchen-salt', '>= 0.6.0' gem 'kitchen-inspec', '>= 1.1' +gem 'inspec', '~> 4.16.0' diff --git a/kitchen.yml b/kitchen.yml index a9cffff..9575352 100644 --- a/kitchen.yml +++ b/kitchen.yml @@ -62,6 +62,13 @@ platforms: provision_command: - curl -o bootstrap-salt.sh -L https://bootstrap.saltstack.com - sh bootstrap-salt.sh -XdPbfrq -x python2 git develop + - name: arch-base-latest-develop-py2 + driver: + image: netmanagers/salt-develop-py2:arch-base-latest + provision_command: + - curl -o bootstrap-salt.sh -L https://bootstrap.saltstack.com + - sh bootstrap-salt.sh -XdPbfrq -x python2 git develop + run_command: /usr/lib/systemd/systemd ## SALT `2019.2` - name: debian-9-2019-2-py3 @@ -87,6 +94,10 @@ platforms: - name: amazonlinux-2-2019-2-py2 driver: image: netmanagers/salt-2019.2-py2:amazonlinux-2 + - name: arch-base-latest-2019-2-py2 + driver: + image: netmanagers/salt-2019.2-py2:arch-base-latest + run_command: /usr/lib/systemd/systemd ## SALT `2018.3` - name: debian-9-2018-3-py2 @@ -112,6 +123,10 @@ platforms: - name: amazonlinux-2-2018-3-py2 driver: image: netmanagers/salt-2018.3-py2:amazonlinux-2 + - name: arch-base-latest-2018-3-py2 + driver: + image: netmanagers/salt-2018.3-py2:arch-base-latest + run_command: /usr/lib/systemd/systemd ## SALT `2017.7` - name: debian-8-2017-7-py2 @@ -138,6 +153,10 @@ platforms: - name: amazonlinux-2-2017-7-py2 driver: image: netmanagers/salt-2017.7-py2:amazonlinux-2 + - name: arch-base-latest-2017-7-py2 + driver: + image: netmanagers/salt-2017.7-py2:arch-base-latest + run_command: /usr/lib/systemd/systemd provisioner: name: salt_solo diff --git a/test/integration/dev_server/vault_spec.rb b/test/integration/dev_server/controls/vault_spec.rb similarity index 91% rename from test/integration/dev_server/vault_spec.rb rename to test/integration/dev_server/controls/vault_spec.rb index 8ad9c2b..b54aa9c 100644 --- a/test/integration/dev_server/vault_spec.rb +++ b/test/integration/dev_server/controls/vault_spec.rb @@ -7,7 +7,7 @@ describe.one do describe file('/etc/systemd/system/vault.service') do it { should be_a_file } - its(:content) { should_not match /syslog/ } + its(:content) { should_not match(/syslog/) } end describe file('/etc/init/vault.conf') do @@ -28,7 +28,7 @@ describe command('journalctl -u vault') do its(:exit_status) { should eq 0 } its(:stderr) { should be_empty } - its(:stdout) { should match /WARNING! dev mode is enabled!/ } + its(:stdout) { should match(/WARNING! dev mode is enabled!/) } end describe file('/var/log/vault.log') do diff --git a/test/integration/dev_server/inspec.yml b/test/integration/dev_server/inspec.yml index c855429..bb8d77e 100644 --- a/test/integration/dev_server/inspec.yml +++ b/test/integration/dev_server/inspec.yml @@ -15,3 +15,4 @@ supports: - platform-name: suse - platform-name: freebsd - platform-name: amazon + - platform-name: arch diff --git a/test/integration/install_binary/vault_spec.rb b/test/integration/install_binary/controls/vault_spec.rb similarity index 100% rename from test/integration/install_binary/vault_spec.rb rename to test/integration/install_binary/controls/vault_spec.rb diff --git a/test/integration/install_binary/inspec.yml b/test/integration/install_binary/inspec.yml index b923123..230e723 100644 --- a/test/integration/install_binary/inspec.yml +++ b/test/integration/install_binary/inspec.yml @@ -15,3 +15,4 @@ supports: - platform-name: suse - platform-name: freebsd - platform-name: amazon + - platform-name: arch diff --git a/test/integration/prod_server/vault_spec.rb b/test/integration/prod_server/controls/vault_spec.rb similarity index 94% rename from test/integration/prod_server/vault_spec.rb rename to test/integration/prod_server/controls/vault_spec.rb index 1eb2989..8221db6 100644 --- a/test/integration/prod_server/vault_spec.rb +++ b/test/integration/prod_server/controls/vault_spec.rb @@ -25,7 +25,7 @@ describe.one do describe file('/etc/systemd/system/vault.service') do it { should be_a_file } - its(:content) { should_not match /syslog/ } + its(:content) { should_not match(/syslog/) } end describe file('/etc/init/vault.conf') do @@ -42,7 +42,7 @@ describe command('journalctl -u vault') do its(:exit_status) { should eq 0 } its(:stderr) { should be_empty } - its(:stdout) { should match /Vault server started/ } + its(:stdout) { should match(/Vault server started/) } end describe file('/var/log/vault.log') do diff --git a/test/integration/prod_server/inspec.yml b/test/integration/prod_server/inspec.yml index d0dd008..e1dce25 100644 --- a/test/integration/prod_server/inspec.yml +++ b/test/integration/prod_server/inspec.yml @@ -15,3 +15,4 @@ supports: - platform-name: suse - platform-name: freebsd - platform-name: amazon + - platform-name: arch diff --git a/vault/osfamilymap.yaml b/vault/osfamilymap.yaml index c75535c..54aca4c 100644 --- a/vault/osfamilymap.yaml +++ b/vault/osfamilymap.yaml @@ -8,5 +8,8 @@ Suse: gpg_pkg: gpg2 setcap_pkg: libcap-progs +Arch: + gpg_pkg: gnupg + MacOS: platform: darwin_amd64