-
Notifications
You must be signed in to change notification settings - Fork 70
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #114 from atomic111/master
Use new InSpec integration tests
- Loading branch information
Showing
9 changed files
with
191 additions
and
88 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
--- | ||
driver: | ||
name: vagrant | ||
|
||
provisioner: | ||
name: chef_solo | ||
|
||
platforms: | ||
- name: ubuntu-12.04 | ||
driver_config: | ||
box: ubuntu/precise64 | ||
box_url: https://atlas.hashicorp.com/ubuntu/boxes/precise64/versions/20150730.1.0/providers/virtualbox.box | ||
- name: ubuntu-14.04 | ||
driver_config: | ||
box: ubuntu/trusty64 | ||
box_url: https://atlas.hashicorp.com/ubuntu/boxes/trusty64/versions/20150609.0.10/providers/virtualbox.box | ||
- name: centos-6.4 | ||
driver_config: | ||
box: opscode-centos-6.4 | ||
box_url: https://opscode-vm.s3.amazonaws.com/vagrant/opscode_centos-6.4_provisionerless.box | ||
- name: centos-6.5 | ||
driver_config: | ||
box: opscode-centos-6.5 | ||
box_url: https://opscode-vm-bento.s3.amazonaws.com/vagrant/virtualbox/opscode_centos-6.5_chef-provisionerless.box | ||
- name: centos-7.1 | ||
driver_config: | ||
box: opscode-centos-7.1 | ||
box_url: https://opscode-vm-bento.s3.amazonaws.com/vagrant/virtualbox/opscode_centos-7.1_chef-provisionerless.box | ||
- name: oracle-6.4 | ||
driver_config: | ||
box: oracle-6.4 | ||
box_url: https://storage.us2.oraclecloud.com/v1/istoilis-istoilis/vagrant/oel64-64.box | ||
- name: oracle-6.5 | ||
driver_config: | ||
box: oracle-6.5 | ||
box_url: https://storage.us2.oraclecloud.com/v1/istoilis-istoilis/vagrant/oel65-64.box | ||
- name: debian-6 | ||
driver_config: | ||
box: ffuenf/debian-6.0.10-amd64 | ||
box_url: https://atlas.hashicorp.com/ffuenf/boxes/debian-6.0.10-amd64/versions/1.0.11/providers/virtualbox.box | ||
- name: debian-7 | ||
driver_config: | ||
box: debian/wheezy64 | ||
box_url: https://atlas.hashicorp.com/debian/boxes/wheezy64/versions/7.8.5/providers/virtualbox.box | ||
- name: debian-8 | ||
driver_config: | ||
box: debian/jessie64 | ||
box_url: https://atlas.hashicorp.com/debian/boxes/jessie64/versions/8.1.0/providers/virtualbox.box | ||
|
||
verifier: | ||
name: inspec | ||
sudo: true | ||
|
||
suites: | ||
- name: default | ||
run_list: | ||
- recipe[ssh-hardening] | ||
verifier: | ||
inspec_tests: | ||
- https://github.com/dev-sec/tests-ssh-hardening |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,53 +1,78 @@ | ||
--- | ||
driver: | ||
name: vagrant | ||
name: dokken | ||
chef_version: 12.5.1 | ||
privileged: true # because Docker and SystemD/Upstart | ||
|
||
transport: | ||
name: dokken | ||
|
||
provisioner: | ||
name: chef_solo | ||
test_repo_uri: https://github.com/TelekomLabs/tests-ssh-hardening.git | ||
name: dokken | ||
|
||
verifier: | ||
name: inspec | ||
sudo: true | ||
|
||
platforms: | ||
- name: ubuntu-12.04 | ||
driver_config: | ||
box: ubuntu/precise64 | ||
box_url: https://atlas.hashicorp.com/ubuntu/boxes/precise64/versions/20150730.1.0/providers/virtualbox.box | ||
driver: | ||
image: ubuntu:12.04 | ||
- name: ubuntu-14.04 | ||
driver_config: | ||
box: ubuntu/trusty64 | ||
box_url: https://atlas.hashicorp.com/ubuntu/boxes/trusty64/versions/20150609.0.10/providers/virtualbox.box | ||
- name: centos-6.4 | ||
driver_config: | ||
box: opscode-centos-6.4 | ||
box_url: https://opscode-vm.s3.amazonaws.com/vagrant/opscode_centos-6.4_provisionerless.box | ||
- name: centos-6.5 | ||
driver_config: | ||
box: opscode-centos-6.5 | ||
box_url: https://opscode-vm-bento.s3.amazonaws.com/vagrant/virtualbox/opscode_centos-6.5_chef-provisionerless.box | ||
- name: centos-7.1 | ||
driver_config: | ||
box: opscode-centos-7.1 | ||
box_url: https://opscode-vm-bento.s3.amazonaws.com/vagrant/virtualbox/opscode_centos-7.1_chef-provisionerless.box | ||
- name: oracle-6.4 | ||
driver_config: | ||
box: oracle-6.4 | ||
box_url: https://storage.us2.oraclecloud.com/v1/istoilis-istoilis/vagrant/oel64-64.box | ||
- name: oracle-6.5 | ||
driver_config: | ||
box: oracle-6.5 | ||
box_url: https://storage.us2.oraclecloud.com/v1/istoilis-istoilis/vagrant/oel65-64.box | ||
- name: debian-6 | ||
driver_config: | ||
box: ffuenf/debian-6.0.10-amd64 | ||
box_url: https://atlas.hashicorp.com/ffuenf/boxes/debian-6.0.10-amd64/versions/1.0.11/providers/virtualbox.box | ||
driver: | ||
image: ubuntu:14.04 | ||
- name: ubuntu-15.10 | ||
driver: | ||
image: ubuntu:15.10 | ||
pid_one_command: /bin/systemd | ||
- name: ubuntu-16.04 | ||
driver: | ||
image: ubuntu:16.04 | ||
intermediate_instructions: | ||
- RUN /usr/bin/apt-get update | ||
pid_one_command: /bin/systemd | ||
- name: centos-6.6 | ||
driver: | ||
image: centos:6.6 | ||
- name: centos-6.7 | ||
driver: | ||
image: centos:6.7 | ||
intermediate_instructions: | ||
- RUN yum install -y initscripts | ||
- name: centos-7 | ||
driver: | ||
image: centos:7 | ||
pid_one_command: /usr/lib/systemd/systemd | ||
- name: oracle-6.6 | ||
driver: | ||
image: oraclelinux:6.6 | ||
- name: oracle-6.7 | ||
driver: | ||
image: oraclelinux:6.7 | ||
- name: oracle-7.1 | ||
driver: | ||
image: oraclelinux:7.1 | ||
pid_one_command: /usr/lib/systemd/systemd | ||
- name: debian-7 | ||
driver_config: | ||
box: debian/wheezy64 | ||
box_url: https://atlas.hashicorp.com/debian/boxes/wheezy64/versions/7.8.5/providers/virtualbox.box | ||
driver: | ||
image: debian:7 | ||
intermediate_instructions: | ||
- RUN /usr/bin/apt-get update | ||
- RUN /usr/bin/apt-get install -y procps | ||
- name: debian-8 | ||
driver_config: | ||
box: debian/jessie64 | ||
box_url: https://atlas.hashicorp.com/debian/boxes/jessie64/versions/8.1.0/providers/virtualbox.box | ||
verifier: | ||
name: inspec | ||
driver: | ||
image: debian:8 | ||
intermediate_instructions: | ||
- RUN /usr/bin/apt-get update | ||
- RUN /usr/bin/apt-get install -y procps | ||
pid_one_command: /bin/systemd | ||
|
||
suites: | ||
- name: default | ||
run_list: | ||
- - role[ssh] | ||
- recipe[apt] | ||
- recipe[yum] | ||
- recipe[ssh-hardening::default] | ||
verifier: | ||
inspec_tests: | ||
- https://github.com/dev-sec/tests-ssh-hardening |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,28 @@ | ||
--- | ||
rvm: | ||
- 2.0.0 | ||
- 2.1.3 | ||
gemfile: | ||
- Gemfile | ||
- gemfile.chef-11 | ||
sudo: required | ||
language: ruby | ||
bundler_args: "--without development integration openstack" | ||
cache: bundler | ||
dist: trusty | ||
|
||
services: | ||
- docker | ||
|
||
before_install: | ||
- gem --version | ||
- bundle version | ||
|
||
matrix: | ||
include: | ||
# verify lint and unit | ||
- rvm: 2.3.1 | ||
gemfile: Gemfile | ||
bundler_args: "--without integration guard tools" | ||
# integration tests | ||
- rvm: 2.3.1 | ||
bundler_args: "--without guard tools" | ||
script: bundle exec rake test:integration OS='centos oracle' | ||
gemfile: Gemfile | ||
- rvm: 2.3.1 | ||
bundler_args: "--without guard tools" | ||
script: bundle exec rake test:integration OS='ubuntu debian' | ||
gemfile: Gemfile |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters