inspec 0.9.10 → 0.9.11
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +22 -2
- data/Gemfile +1 -0
- data/README.md +2 -1
- data/bin/inspec +4 -1
- data/docs/dsl_resource.rst +2 -2
- data/docs/profiles.rst +5 -3
- data/examples/profile/README.md +1 -1
- data/inspec.gemspec +1 -1
- data/lib/inspec/version.rb +1 -1
- data/lib/resources/etc_group.rb +1 -1
- data/lib/resources/file.rb +5 -1
- data/lib/resources/package.rb +63 -9
- data/lib/resources/port.rb +47 -7
- data/lib/resources/service.rb +53 -15
- data/lib/resources/user.rb +42 -21
- data/lib/utils/parser.rb +85 -0
- data/test/helper.rb +8 -0
- data/test/integration/.kitchen.chef.yml +29 -0
- data/test/integration/.kitchen.ec2.yml +10 -4
- data/test/integration/.kitchen.shell.yml +19 -0
- data/test/integration/.kitchen/default-chef-solaris-1011.yml +6 -0
- data/test/integration/.kitchen/default-chef-windows-server-2008r2-standard.yml +7 -0
- data/test/integration/.kitchen/default-chef-windows-server-2012r2-standard.yml +7 -0
- data/test/integration/.kitchen/default-chris-rock-omnios-r151014.yml +6 -0
- data/test/integration/.kitchen/default-debian-81.yml +6 -0
- data/test/integration/.kitchen/default-omniti-omnios-r151014.yml +1 -0
- data/test/integration/.kitchen/default-windows-2008.yml +5 -0
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-chef-solaris-1011/.vagrant/machines/default/virtualbox/action_set_name +1 -0
- data/test/integration/.kitchen/kitchen-vagrant/{kitchen-integration-default-fedora-22 → kitchen-integration-default-chef-solaris-1011}/.vagrant/machines/default/virtualbox/creator_uid +0 -0
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-chef-solaris-1011/.vagrant/machines/default/virtualbox/id +1 -0
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-chef-solaris-1011/.vagrant/machines/default/virtualbox/index_uuid +1 -0
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-chef-solaris-1011/.vagrant/machines/default/virtualbox/private_key +27 -0
- data/test/integration/.kitchen/kitchen-vagrant/{kitchen-integration-default-fedora-22 → kitchen-integration-default-chef-solaris-1011}/.vagrant/machines/default/virtualbox/synced_folders +0 -0
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-chef-solaris-1011/Vagrantfile +8 -0
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-chef-windows-server-2008r2-standard/.vagrant/machines/default/virtualbox/action_set_name +1 -0
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-chef-windows-server-2008r2-standard/.vagrant/machines/default/virtualbox/creator_uid +1 -0
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-chef-windows-server-2008r2-standard/.vagrant/machines/default/virtualbox/id +1 -0
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-chef-windows-server-2008r2-standard/.vagrant/machines/default/virtualbox/index_uuid +1 -0
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-chef-windows-server-2008r2-standard/.vagrant/machines/default/virtualbox/synced_folders +1 -0
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-chef-windows-server-2008r2-standard/Vagrantfile +7 -0
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-chef-windows-server-2012r2-standard/.vagrant/machines/default/virtualbox/action_set_name +1 -0
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-chef-windows-server-2012r2-standard/.vagrant/machines/default/virtualbox/creator_uid +1 -0
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-chef-windows-server-2012r2-standard/.vagrant/machines/default/virtualbox/id +1 -0
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-chef-windows-server-2012r2-standard/.vagrant/machines/default/virtualbox/index_uuid +1 -0
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-chef-windows-server-2012r2-standard/.vagrant/machines/default/virtualbox/synced_folders +1 -0
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-chef-windows-server-2012r2-standard/Vagrantfile +8 -0
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-chris-rock-omnios-r151014/.vagrant/machines/default/virtualbox/action_set_name +1 -0
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-chris-rock-omnios-r151014/.vagrant/machines/default/virtualbox/creator_uid +1 -0
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-chris-rock-omnios-r151014/.vagrant/machines/default/virtualbox/id +1 -0
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-chris-rock-omnios-r151014/.vagrant/machines/default/virtualbox/index_uuid +1 -0
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-chris-rock-omnios-r151014/.vagrant/machines/default/virtualbox/private_key +27 -0
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-chris-rock-omnios-r151014/.vagrant/machines/default/virtualbox/synced_folders +1 -0
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-chris-rock-omnios-r151014/Vagrantfile +8 -0
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-debian-81/.vagrant/machines/default/virtualbox/action_set_name +1 -0
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-debian-81/.vagrant/machines/default/virtualbox/creator_uid +1 -0
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-debian-81/.vagrant/machines/default/virtualbox/id +1 -0
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-debian-81/.vagrant/machines/default/virtualbox/index_uuid +1 -0
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-debian-81/.vagrant/machines/default/virtualbox/private_key +27 -0
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-debian-81/.vagrant/machines/default/virtualbox/synced_folders +1 -0
- data/test/integration/.kitchen/kitchen-vagrant/{kitchen-integration-default-fedora-22 → kitchen-integration-default-debian-81}/Vagrantfile +3 -3
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-omniti-omnios-r151014/.vagrant/machines/default/virtualbox/action_set_name +1 -0
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-omniti-omnios-r151014/.vagrant/machines/default/virtualbox/creator_uid +1 -0
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-omniti-omnios-r151014/.vagrant/machines/default/virtualbox/id +1 -0
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-omniti-omnios-r151014/.vagrant/machines/default/virtualbox/index_uuid +1 -0
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-omniti-omnios-r151014/.vagrant/machines/default/virtualbox/private_key +27 -0
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-omniti-omnios-r151014/Vagrantfile +8 -0
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-ubuntu-1204/.vagrant/machines/default/virtualbox/action_set_name +1 -1
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-ubuntu-1204/.vagrant/machines/default/virtualbox/id +1 -1
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-ubuntu-1204/.vagrant/machines/default/virtualbox/index_uuid +1 -1
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-ubuntu-1204/.vagrant/machines/default/virtualbox/private_key +25 -25
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-ubuntu-1404/.vagrant/machines/default/virtualbox/action_set_name +1 -1
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-ubuntu-1404/.vagrant/machines/default/virtualbox/id +1 -1
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-ubuntu-1404/.vagrant/machines/default/virtualbox/index_uuid +1 -1
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-ubuntu-1404/.vagrant/machines/default/virtualbox/private_key +25 -25
- data/test/integration/.kitchen/logs/default-aws-linux.log +3 -0
- data/test/integration/.kitchen/logs/default-centos-511-i386.log +0 -2
- data/test/integration/.kitchen/logs/default-centos-511.log +0 -2
- data/test/integration/.kitchen/logs/default-centos-67-i386.log +0 -2
- data/test/integration/.kitchen/logs/default-centos-67.log +0 -2
- data/test/integration/.kitchen/logs/default-centos-7.log +3 -0
- data/test/integration/.kitchen/logs/default-centos-71.log +0 -2
- data/test/integration/.kitchen/logs/default-chef-solaris-1011.log +0 -0
- data/test/integration/.kitchen/logs/default-chef-windows-server-2008r2-standard.log +0 -0
- data/test/integration/.kitchen/logs/default-chef-windows-server-2012r2-standard.log +0 -0
- data/test/integration/.kitchen/logs/default-chris-rock-omnios-r151014.log +23 -0
- data/test/integration/.kitchen/logs/default-debian-6010-i386.log +0 -2
- data/test/integration/.kitchen/logs/default-debian-6010.log +0 -2
- data/test/integration/.kitchen/logs/default-debian-78-i386.log +0 -2
- data/test/integration/.kitchen/logs/default-debian-78.log +0 -2
- data/test/integration/.kitchen/logs/default-debian-8.log +3 -0
- data/test/integration/.kitchen/logs/default-debian-81-i386.log +0 -2
- data/test/integration/.kitchen/logs/default-debian-81.log +240 -2
- data/test/integration/.kitchen/logs/default-dusank-oi-server.log +0 -0
- data/test/integration/.kitchen/logs/default-fedora-21-i386.log +0 -2
- data/test/integration/.kitchen/logs/default-fedora-21.log +0 -2
- data/test/integration/.kitchen/logs/default-fedora-22.log +3 -0
- data/test/integration/.kitchen/logs/default-freebsd-102.log +0 -2
- data/test/integration/.kitchen/logs/default-freebsd-93.log +0 -2
- data/test/integration/.kitchen/logs/default-livinginthepast-smartos-base64.log +0 -0
- data/test/integration/.kitchen/logs/default-mint-172-cinnamon.log +0 -2
- data/test/integration/.kitchen/logs/default-omniti-omnios-r151014.log +0 -0
- data/test/integration/.kitchen/logs/default-opensuse-132-i386.log +0 -2
- data/test/integration/.kitchen/logs/default-opensuse-132-x86-64.log +0 -2
- data/test/integration/.kitchen/logs/default-redhat-65.log +3 -0
- data/test/integration/.kitchen/logs/default-redhat-71.log +3 -0
- data/test/integration/.kitchen/logs/default-suse-11sp3.log +3 -0
- data/test/integration/.kitchen/logs/default-suse-12.log +3 -0
- data/test/integration/.kitchen/logs/default-ubuntu-1004-i386.log +0 -2
- data/test/integration/.kitchen/logs/default-ubuntu-1004.log +0 -2
- data/test/integration/.kitchen/logs/default-ubuntu-1204-i386.log +0 -2
- data/test/integration/.kitchen/logs/default-ubuntu-1204.log +3 -0
- data/test/integration/.kitchen/logs/default-ubuntu-1404-i386.log +0 -2
- data/test/integration/.kitchen/logs/default-ubuntu-1404.log +3 -0
- data/test/integration/.kitchen/logs/default-ubuntu-1510.log +3 -0
- data/test/integration/.kitchen/logs/default-windows-2012r2.log +2 -41
- data/test/integration/.kitchen/logs/default-winrm.log +0 -0
- data/test/integration/.kitchen/logs/kitchen.log +14 -0
- data/test/integration/bootstrap.sh +3 -0
- data/test/integration/cookbooks/os_prepare/recipes/file.rb +2 -0
- data/test/integration/cookbooks/os_prepare/recipes/json_yaml_csv_ini.rb +2 -0
- data/test/integration/cookbooks/os_prepare/recipes/mount.rb +24 -20
- data/test/integration/cookbooks/os_prepare/templates/default/sv-default-svlog-run.erb +1 -2
- data/test/integration/test/integration/default/_debug_spec.rb +1 -1
- data/test/integration/test/integration/default/compare_matcher_spec.rb +15 -13
- data/test/integration/test/integration/default/etc_group_spec.rb +9 -8
- data/test/integration/test/integration/default/file_spec.rb +14 -4
- data/test/integration/test/integration/default/group_spec.rb +17 -7
- data/test/integration/test/integration/default/mount_spec.rb +9 -7
- data/test/integration/test/integration/default/package_spec.rb +16 -0
- data/test/integration/test/integration/default/port_spec.rb +8 -2
- data/test/integration/test/integration/default/service_spec.rb +4 -1
- data/test/integration/test/integration/default/user_spec.rb +37 -14
- data/test/unit/mock/cmd/pkg-info-system-file-system-zfs +8 -0
- data/test/unit/mock/cmd/pkginfo-l-SUNWzfsr +7 -0
- data/test/unit/mock/cmd/s11-netstat-an-finet-finet6 +32 -0
- data/test/unit/resources/file_test.rb +1 -0
- data/test/unit/resources/package_test.rb +18 -0
- data/test/unit/resources/port_test.rb +10 -0
- data/test/unit/utils/passwd_parser_test.rb +2 -0
- data/test/unit/utils/solaris_netstat_parser.rb +124 -0
- metadata +127 -42
- data/lib/extras/compliance/README.md +0 -15
- data/lib/extras/compliance/compliance.rb +0 -245
- data/test/integration/.kitchen/default-aws-linux.yml +0 -4
- data/test/integration/.kitchen/default-centos-7.yml +0 -4
- data/test/integration/.kitchen/default-debian-8.yml +0 -4
- data/test/integration/.kitchen/default-fedora-22.yml +0 -4
- data/test/integration/.kitchen/default-redhat-65.yml +0 -4
- data/test/integration/.kitchen/default-redhat-71.yml +0 -4
- data/test/integration/.kitchen/default-suse-11sp3.yml +0 -4
- data/test/integration/.kitchen/default-suse-12.yml +0 -4
- data/test/integration/.kitchen/default-ubuntu-1204.yml +0 -3
- data/test/integration/.kitchen/default-ubuntu-1404.yml +0 -4
- data/test/integration/.kitchen/default-windows-2012r2.yml +0 -2
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-fedora-22/.vagrant/machines/default/virtualbox/action_set_name +0 -1
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-fedora-22/.vagrant/machines/default/virtualbox/id +0 -1
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-fedora-22/.vagrant/machines/default/virtualbox/index_uuid +0 -1
- data/test/integration/.kitchen/kitchen-vagrant/kitchen-integration-default-fedora-22/.vagrant/machines/default/virtualbox/private_key +0 -27
File without changes
|
@@ -0,0 +1,3 @@
|
|
1
|
+
I, [2016-01-29T18:18:29.159178 #96612] INFO -- default-fedora-22: -----> Destroying <default-fedora-22>...
|
2
|
+
I, [2016-01-29T18:18:29.427875 #96612] INFO -- default-fedora-22: EC2 instance <i-b738b90b> destroyed.
|
3
|
+
I, [2016-01-29T18:18:29.428400 #96612] INFO -- default-fedora-22: Finished destroying <default-fedora-22> (0m0.27s).
|
File without changes
|
File without changes
|
@@ -0,0 +1,3 @@
|
|
1
|
+
I, [2016-01-29T18:18:27.722177 #96612] INFO -- default-redhat-65: -----> Destroying <default-redhat-65>...
|
2
|
+
I, [2016-01-29T18:18:27.959176 #96612] INFO -- default-redhat-65: EC2 instance <i-ca38b976> destroyed.
|
3
|
+
I, [2016-01-29T18:18:27.960524 #96612] INFO -- default-redhat-65: Finished destroying <default-redhat-65> (0m0.24s).
|
@@ -0,0 +1,3 @@
|
|
1
|
+
I, [2016-01-29T18:18:27.961358 #96612] INFO -- default-redhat-71: -----> Destroying <default-redhat-71>...
|
2
|
+
I, [2016-01-29T18:18:28.228198 #96612] INFO -- default-redhat-71: EC2 instance <i-4238b9fe> destroyed.
|
3
|
+
I, [2016-01-29T18:18:28.229964 #96612] INFO -- default-redhat-71: Finished destroying <default-redhat-71> (0m0.27s).
|
@@ -0,0 +1,3 @@
|
|
1
|
+
I, [2016-01-29T18:18:26.706567 #96612] INFO -- default-suse-11sp3: -----> Destroying <default-suse-11sp3>...
|
2
|
+
I, [2016-01-29T18:18:27.453489 #96612] INFO -- default-suse-11sp3: EC2 instance <i-b938b905> destroyed.
|
3
|
+
I, [2016-01-29T18:18:27.454121 #96612] INFO -- default-suse-11sp3: Finished destroying <default-suse-11sp3> (0m0.75s).
|
@@ -0,0 +1,3 @@
|
|
1
|
+
I, [2016-01-29T18:18:27.454966 #96612] INFO -- default-suse-12: -----> Destroying <default-suse-12>...
|
2
|
+
I, [2016-01-29T18:18:27.719270 #96612] INFO -- default-suse-12: EC2 instance <i-4538b9f9> destroyed.
|
3
|
+
I, [2016-01-29T18:18:27.721314 #96612] INFO -- default-suse-12: Finished destroying <default-suse-12> (0m0.26s).
|
@@ -0,0 +1,3 @@
|
|
1
|
+
I, [2016-01-29T18:18:28.232601 #96612] INFO -- default-ubuntu-1204: -----> Destroying <default-ubuntu-1204>...
|
2
|
+
I, [2016-01-29T18:18:28.575969 #96612] INFO -- default-ubuntu-1204: EC2 instance <i-3c39b880> destroyed.
|
3
|
+
I, [2016-01-29T18:18:28.576602 #96612] INFO -- default-ubuntu-1204: Finished destroying <default-ubuntu-1204> (0m0.34s).
|
@@ -0,0 +1,3 @@
|
|
1
|
+
I, [2016-01-29T18:18:28.577693 #96612] INFO -- default-ubuntu-1404: -----> Destroying <default-ubuntu-1404>...
|
2
|
+
I, [2016-01-29T18:18:28.882177 #96612] INFO -- default-ubuntu-1404: EC2 instance <i-b838b904> destroyed.
|
3
|
+
I, [2016-01-29T18:18:28.883859 #96612] INFO -- default-ubuntu-1404: Finished destroying <default-ubuntu-1404> (0m0.30s).
|
@@ -0,0 +1,3 @@
|
|
1
|
+
I, [2016-01-29T18:18:28.884908 #96612] INFO -- default-ubuntu-1510: -----> Destroying <default-ubuntu-1510>...
|
2
|
+
I, [2016-01-29T18:18:29.156782 #96612] INFO -- default-ubuntu-1510: EC2 instance <i-3d39b881> destroyed.
|
3
|
+
I, [2016-01-29T18:18:29.158221 #96612] INFO -- default-ubuntu-1510: Finished destroying <default-ubuntu-1510> (0m0.27s).
|
@@ -1,41 +1,2 @@
|
|
1
|
-
I, [2016-01-
|
2
|
-
I, [2016-01-
|
3
|
-
free-tier, you may be charged to run these suites. The charge
|
4
|
-
should be minimal, but neither Test Kitchen nor its maintainers
|
5
|
-
are responsible for your incurred costs.
|
6
|
-
|
7
|
-
E, [2016-01-25T17:25:07.834439 #42763] ERROR -- default-windows-2012r2: Create failed on instance <default-windows-2012r2>.
|
8
|
-
E, [2016-01-25T17:25:07.834698 #42763] ERROR -- default-windows-2012r2: ------Exception-------
|
9
|
-
E, [2016-01-25T17:25:07.834716 #42763] ERROR -- default-windows-2012r2: Class: Aws::EC2::Errors::AuthFailure
|
10
|
-
E, [2016-01-25T17:25:07.834726 #42763] ERROR -- default-windows-2012r2: Message: Not authorized for images: [ami-f2f5f9ef]
|
11
|
-
E, [2016-01-25T17:25:07.834735 #42763] ERROR -- default-windows-2012r2: ------Backtrace-------
|
12
|
-
E, [2016-01-25T17:25:07.834743 #42763] ERROR -- default-windows-2012r2: /Users/chartmann/.rvm/rubies/ruby-2.2.1/lib/ruby/gems/2.2.0/gems/aws-sdk-core-2.2.13/lib/seahorse/client/plugins/raise_response_errors.rb:15:in `call'
|
13
|
-
E, [2016-01-25T17:25:07.834755 #42763] ERROR -- default-windows-2012r2: /Users/chartmann/.rvm/rubies/ruby-2.2.1/lib/ruby/gems/2.2.0/gems/aws-sdk-core-2.2.13/lib/aws-sdk-core/plugins/param_converter.rb:20:in `call'
|
14
|
-
E, [2016-01-25T17:25:07.834765 #42763] ERROR -- default-windows-2012r2: /Users/chartmann/.rvm/rubies/ruby-2.2.1/lib/ruby/gems/2.2.0/gems/aws-sdk-core-2.2.13/lib/seahorse/client/plugins/response_target.rb:21:in `call'
|
15
|
-
E, [2016-01-25T17:25:07.834773 #42763] ERROR -- default-windows-2012r2: /Users/chartmann/.rvm/rubies/ruby-2.2.1/lib/ruby/gems/2.2.0/gems/aws-sdk-core-2.2.13/lib/seahorse/client/request.rb:70:in `send_request'
|
16
|
-
E, [2016-01-25T17:25:07.834782 #42763] ERROR -- default-windows-2012r2: /Users/chartmann/.rvm/rubies/ruby-2.2.1/lib/ruby/gems/2.2.0/gems/aws-sdk-core-2.2.13/lib/seahorse/client/base.rb:207:in `block (2 levels) in define_operation_methods'
|
17
|
-
E, [2016-01-25T17:25:07.834791 #42763] ERROR -- default-windows-2012r2: /Users/chartmann/.rvm/rubies/ruby-2.2.1/lib/ruby/gems/2.2.0/gems/aws-sdk-resources-2.2.13/lib/aws-sdk-resources/request.rb:24:in `call'
|
18
|
-
E, [2016-01-25T17:25:07.834799 #42763] ERROR -- default-windows-2012r2: /Users/chartmann/.rvm/rubies/ruby-2.2.1/lib/ruby/gems/2.2.0/gems/aws-sdk-resources-2.2.13/lib/aws-sdk-resources/operations.rb:41:in `call'
|
19
|
-
E, [2016-01-25T17:25:07.834808 #42763] ERROR -- default-windows-2012r2: /Users/chartmann/.rvm/rubies/ruby-2.2.1/lib/ruby/gems/2.2.0/gems/aws-sdk-resources-2.2.13/lib/aws-sdk-resources/operations.rb:87:in `call'
|
20
|
-
E, [2016-01-25T17:25:07.834816 #42763] ERROR -- default-windows-2012r2: /Users/chartmann/.rvm/rubies/ruby-2.2.1/lib/ruby/gems/2.2.0/gems/aws-sdk-resources-2.2.13/lib/aws-sdk-resources/operation_methods.rb:19:in `block in add_operation'
|
21
|
-
E, [2016-01-25T17:25:07.834825 #42763] ERROR -- default-windows-2012r2: /Users/chartmann/.rvm/rubies/ruby-2.2.1/lib/ruby/gems/2.2.0/gems/kitchen-ec2-0.10.0/lib/kitchen/driver/aws/client.rb:82:in `create_instance'
|
22
|
-
E, [2016-01-25T17:25:07.834833 #42763] ERROR -- default-windows-2012r2: /Users/chartmann/.rvm/rubies/ruby-2.2.1/lib/ruby/gems/2.2.0/gems/kitchen-ec2-0.10.0/lib/kitchen/driver/ec2.rb:291:in `submit_server'
|
23
|
-
E, [2016-01-25T17:25:07.834842 #42763] ERROR -- default-windows-2012r2: /Users/chartmann/.rvm/rubies/ruby-2.2.1/lib/ruby/gems/2.2.0/gems/kitchen-ec2-0.10.0/lib/kitchen/driver/ec2.rb:192:in `create'
|
24
|
-
E, [2016-01-25T17:25:07.834853 #42763] ERROR -- default-windows-2012r2: /Users/chartmann/.rvm/rubies/ruby-2.2.1/lib/ruby/gems/2.2.0/gems/test-kitchen-1.5.0/lib/kitchen/instance.rb:431:in `public_send'
|
25
|
-
E, [2016-01-25T17:25:07.834862 #42763] ERROR -- default-windows-2012r2: /Users/chartmann/.rvm/rubies/ruby-2.2.1/lib/ruby/gems/2.2.0/gems/test-kitchen-1.5.0/lib/kitchen/instance.rb:431:in `block in perform_action'
|
26
|
-
E, [2016-01-25T17:25:07.834871 #42763] ERROR -- default-windows-2012r2: /Users/chartmann/.rvm/rubies/ruby-2.2.1/lib/ruby/gems/2.2.0/gems/test-kitchen-1.5.0/lib/kitchen/instance.rb:495:in `call'
|
27
|
-
E, [2016-01-25T17:25:07.834931 #42763] ERROR -- default-windows-2012r2: /Users/chartmann/.rvm/rubies/ruby-2.2.1/lib/ruby/gems/2.2.0/gems/test-kitchen-1.5.0/lib/kitchen/instance.rb:495:in `synchronize_or_call'
|
28
|
-
E, [2016-01-25T17:25:07.834943 #42763] ERROR -- default-windows-2012r2: /Users/chartmann/.rvm/rubies/ruby-2.2.1/lib/ruby/gems/2.2.0/gems/test-kitchen-1.5.0/lib/kitchen/instance.rb:460:in `block in action'
|
29
|
-
E, [2016-01-25T17:25:07.834952 #42763] ERROR -- default-windows-2012r2: /Users/chartmann/.rvm/rubies/ruby-2.2.1/lib/ruby/2.2.0/benchmark.rb:288:in `measure'
|
30
|
-
E, [2016-01-25T17:25:07.834961 #42763] ERROR -- default-windows-2012r2: /Users/chartmann/.rvm/rubies/ruby-2.2.1/lib/ruby/gems/2.2.0/gems/test-kitchen-1.5.0/lib/kitchen/instance.rb:459:in `action'
|
31
|
-
E, [2016-01-25T17:25:07.834969 #42763] ERROR -- default-windows-2012r2: /Users/chartmann/.rvm/rubies/ruby-2.2.1/lib/ruby/gems/2.2.0/gems/test-kitchen-1.5.0/lib/kitchen/instance.rb:431:in `perform_action'
|
32
|
-
E, [2016-01-25T17:25:07.834977 #42763] ERROR -- default-windows-2012r2: /Users/chartmann/.rvm/rubies/ruby-2.2.1/lib/ruby/gems/2.2.0/gems/test-kitchen-1.5.0/lib/kitchen/instance.rb:359:in `create_action'
|
33
|
-
E, [2016-01-25T17:25:07.834986 #42763] ERROR -- default-windows-2012r2: /Users/chartmann/.rvm/rubies/ruby-2.2.1/lib/ruby/gems/2.2.0/gems/test-kitchen-1.5.0/lib/kitchen/instance.rb:348:in `block in transition_to'
|
34
|
-
E, [2016-01-25T17:25:07.834994 #42763] ERROR -- default-windows-2012r2: /Users/chartmann/.rvm/rubies/ruby-2.2.1/lib/ruby/gems/2.2.0/gems/test-kitchen-1.5.0/lib/kitchen/instance.rb:347:in `each'
|
35
|
-
E, [2016-01-25T17:25:07.835005 #42763] ERROR -- default-windows-2012r2: /Users/chartmann/.rvm/rubies/ruby-2.2.1/lib/ruby/gems/2.2.0/gems/test-kitchen-1.5.0/lib/kitchen/instance.rb:347:in `transition_to'
|
36
|
-
E, [2016-01-25T17:25:07.835015 #42763] ERROR -- default-windows-2012r2: /Users/chartmann/.rvm/rubies/ruby-2.2.1/lib/ruby/gems/2.2.0/gems/test-kitchen-1.5.0/lib/kitchen/instance.rb:138:in `converge'
|
37
|
-
E, [2016-01-25T17:25:07.835023 #42763] ERROR -- default-windows-2012r2: /Users/chartmann/.rvm/rubies/ruby-2.2.1/lib/ruby/gems/2.2.0/gems/test-kitchen-1.5.0/lib/kitchen/command.rb:176:in `public_send'
|
38
|
-
E, [2016-01-25T17:25:07.835032 #42763] ERROR -- default-windows-2012r2: /Users/chartmann/.rvm/rubies/ruby-2.2.1/lib/ruby/gems/2.2.0/gems/test-kitchen-1.5.0/lib/kitchen/command.rb:176:in `block (2 levels) in run_action'
|
39
|
-
E, [2016-01-25T17:25:07.835040 #42763] ERROR -- default-windows-2012r2: /Users/chartmann/.rvm/rubies/ruby-2.2.1/lib/ruby/gems/2.2.0/gems/logging-2.0.0/lib/logging/diagnostic_context.rb:448:in `call'
|
40
|
-
E, [2016-01-25T17:25:07.835049 #42763] ERROR -- default-windows-2012r2: /Users/chartmann/.rvm/rubies/ruby-2.2.1/lib/ruby/gems/2.2.0/gems/logging-2.0.0/lib/logging/diagnostic_context.rb:448:in `block in create_with_logging_context'
|
41
|
-
E, [2016-01-25T17:25:07.835057 #42763] ERROR -- default-windows-2012r2: ----------------------
|
1
|
+
I, [2016-01-29T18:18:26.704447 #96612] INFO -- default-windows-2012r2: -----> Destroying <default-windows-2012r2>...
|
2
|
+
I, [2016-01-29T18:18:26.705620 #96612] INFO -- default-windows-2012r2: Finished destroying <default-windows-2012r2> (0m0.00s).
|
File without changes
|
@@ -0,0 +1,14 @@
|
|
1
|
+
I, [2016-01-29T18:18:25.774560 #96612] INFO -- Kitchen: -----> Starting Kitchen (v1.5.0)
|
2
|
+
I, [2016-01-29T18:18:26.704395 #96612] INFO -- Kitchen: -----> Destroying <default-windows-2012r2>...
|
3
|
+
I, [2016-01-29T18:18:26.706532 #96612] INFO -- Kitchen: -----> Destroying <default-suse-11sp3>...
|
4
|
+
I, [2016-01-29T18:18:27.454920 #96612] INFO -- Kitchen: -----> Destroying <default-suse-12>...
|
5
|
+
I, [2016-01-29T18:18:27.722146 #96612] INFO -- Kitchen: -----> Destroying <default-redhat-65>...
|
6
|
+
I, [2016-01-29T18:18:27.961328 #96612] INFO -- Kitchen: -----> Destroying <default-redhat-71>...
|
7
|
+
I, [2016-01-29T18:18:28.232545 #96612] INFO -- Kitchen: -----> Destroying <default-ubuntu-1204>...
|
8
|
+
I, [2016-01-29T18:18:28.577646 #96612] INFO -- Kitchen: -----> Destroying <default-ubuntu-1404>...
|
9
|
+
I, [2016-01-29T18:18:28.884854 #96612] INFO -- Kitchen: -----> Destroying <default-ubuntu-1510>...
|
10
|
+
I, [2016-01-29T18:18:29.159142 #96612] INFO -- Kitchen: -----> Destroying <default-fedora-22>...
|
11
|
+
I, [2016-01-29T18:18:29.429401 #96612] INFO -- Kitchen: -----> Destroying <default-debian-8>...
|
12
|
+
I, [2016-01-29T18:18:29.682464 #96612] INFO -- Kitchen: -----> Destroying <default-centos-7>...
|
13
|
+
I, [2016-01-29T18:18:29.918558 #96612] INFO -- Kitchen: -----> Destroying <default-aws-linux>...
|
14
|
+
I, [2016-01-29T18:18:30.349123 #96612] INFO -- Kitchen: -----> Kitchen is finished. (0m4.57s)
|
@@ -4,26 +4,30 @@
|
|
4
4
|
#
|
5
5
|
# file mount tests
|
6
6
|
|
7
|
-
|
8
|
-
|
9
|
-
cookbook_file '/root/empty.iso' do
|
10
|
-
owner 'root'
|
11
|
-
group 'root'
|
12
|
-
mode '0755'
|
13
|
-
action :create
|
14
|
-
end
|
7
|
+
case node['platform']
|
8
|
+
when 'ubuntu', 'rhel', 'centos', 'fedora'
|
15
9
|
|
16
|
-
#
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
10
|
+
# copy iso file for mount tests
|
11
|
+
# NB created using `mkdir empty; mkisofs -o empty.iso empty/`
|
12
|
+
cookbook_file '/root/empty.iso' do
|
13
|
+
owner 'root'
|
14
|
+
group 'root'
|
15
|
+
mode '0755'
|
16
|
+
action :create
|
17
|
+
end
|
18
|
+
|
19
|
+
# create mount directory
|
20
|
+
directory '/mnt/iso-disk' do
|
21
|
+
owner 'root'
|
22
|
+
group 'root'
|
23
|
+
mode '0755'
|
24
|
+
action :create
|
25
|
+
end
|
23
26
|
|
24
|
-
# mount -o loop /root/empty.iso /mnt/iso-disk
|
25
|
-
mount '/mnt/iso-disk' do
|
26
|
-
|
27
|
-
|
28
|
-
|
27
|
+
# mount -o loop /root/empty.iso /mnt/iso-disk
|
28
|
+
mount '/mnt/iso-disk' do
|
29
|
+
device '/root/empty.iso'
|
30
|
+
options 'loop'
|
31
|
+
action [:mount, :enable]
|
32
|
+
end
|
29
33
|
end
|
@@ -1 +1 @@
|
|
1
|
-
p "You are currently running on OS
|
1
|
+
p "You are currently running on OS: #{os[:name] || 'unknown'}, OS release: #{os[:release] || 'unknown'}, OS family: #{os[:family] || 'unknown'}"
|
@@ -1,19 +1,21 @@
|
|
1
1
|
# encoding: utf-8
|
2
2
|
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
3
|
+
if os.linux?
|
4
|
+
# uses the `cmp` matcher instead of the eq matcher
|
5
|
+
describe sshd_config do
|
6
|
+
its('Port') { should eq '22' }
|
7
|
+
its('Port') { should_not eq 22 }
|
7
8
|
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
9
|
+
its('Port') { should cmp '22' }
|
10
|
+
its('Port') { should cmp 22 }
|
11
|
+
its('Port') { should cmp 22.0 }
|
12
|
+
its('Port') { should_not cmp 22.1 }
|
12
13
|
|
13
|
-
|
14
|
-
|
14
|
+
its('LogLevel') { should eq 'INFO' }
|
15
|
+
its('LogLevel') { should_not eq 'info'}
|
15
16
|
|
16
|
-
|
17
|
-
|
18
|
-
|
17
|
+
its('LogLevel') { should cmp 'INFO' }
|
18
|
+
its('LogLevel') { should cmp 'info' }
|
19
|
+
its('LogLevel') { should cmp 'InfO' }
|
20
|
+
end
|
19
21
|
end
|
@@ -1,13 +1,14 @@
|
|
1
1
|
# encoding: utf-8
|
2
2
|
|
3
|
-
root_group =
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
3
|
+
root_group = 'root'
|
4
|
+
|
5
|
+
if os[:family] == 'aix'
|
6
|
+
root_group = 'system'
|
7
|
+
elsif os[:family] == 'freebsd'
|
8
|
+
root_group = 'wheel'
|
9
|
+
elsif os.solaris?
|
10
|
+
root_group = 'sys'
|
11
|
+
end
|
11
12
|
|
12
13
|
if os.unix?
|
13
14
|
describe etc_group do
|
@@ -1,7 +1,6 @@
|
|
1
1
|
# encoding: utf-8
|
2
2
|
|
3
|
-
|
4
|
-
when 'freebsd'
|
3
|
+
if os[:family] == 'freebsd'
|
5
4
|
filedata = {
|
6
5
|
user: 'root',
|
7
6
|
group: 'wheel',
|
@@ -9,7 +8,7 @@ when 'freebsd'
|
|
9
8
|
dir_md5sum: '598f4fe64aefab8f00bcbea4c9239abf',
|
10
9
|
dir_sha256sum: '9b4fb24edd6d1d8830e272398263cdbf026b97392cc35387b991dc0248a628f9',
|
11
10
|
}
|
12
|
-
|
11
|
+
elsif os[:family] == 'aix'
|
13
12
|
filedata = {
|
14
13
|
user: 'root',
|
15
14
|
group: 'system',
|
@@ -17,6 +16,14 @@ when 'aix'
|
|
17
16
|
dir_md5sum: nil,
|
18
17
|
dir_sha256sum: nil,
|
19
18
|
}
|
19
|
+
elsif os.solaris?
|
20
|
+
filedata = {
|
21
|
+
user: 'root',
|
22
|
+
group: 'sys',
|
23
|
+
dir_content: nil,
|
24
|
+
dir_md5sum: nil,
|
25
|
+
dir_sha256sum: nil,
|
26
|
+
}
|
20
27
|
else
|
21
28
|
filedata = {
|
22
29
|
user: 'root',
|
@@ -116,7 +123,9 @@ if os.unix?
|
|
116
123
|
its('group') { should eq filedata[:group] }
|
117
124
|
its('type') { should eq :directory }
|
118
125
|
end
|
126
|
+
end
|
119
127
|
|
128
|
+
if os.linux?
|
120
129
|
# for server spec compatibility
|
121
130
|
# Do not use `.with` or `.only_with`, this syntax is deprecated and will be removed
|
122
131
|
# in InSpec version 1
|
@@ -140,8 +149,9 @@ if os.unix?
|
|
140
149
|
})
|
141
150
|
}
|
142
151
|
end
|
152
|
+
end
|
143
153
|
|
144
|
-
|
154
|
+
if os.windows?
|
145
155
|
describe file('C:\\Windows') do
|
146
156
|
it { should exist }
|
147
157
|
it { should be_directory }
|
@@ -11,10 +11,7 @@ if os.linux?
|
|
11
11
|
it { should_not exist }
|
12
12
|
its('gid') { should eq nil }
|
13
13
|
end
|
14
|
-
|
15
|
-
|
16
|
-
if os[:family] == 'freebsd'
|
17
|
-
|
14
|
+
elsif os[:family] == 'freebsd'
|
18
15
|
describe group('wheel') do
|
19
16
|
it { should exist }
|
20
17
|
its('gid') { should eq 0 }
|
@@ -29,9 +26,7 @@ if os[:family] == 'freebsd'
|
|
29
26
|
it { should_not exist }
|
30
27
|
its('gid') { should eq nil }
|
31
28
|
end
|
32
|
-
|
33
|
-
|
34
|
-
if os[:family] == 'aix'
|
29
|
+
elsif os[:family] == 'aix'
|
35
30
|
describe group('system') do
|
36
31
|
it { should exist }
|
37
32
|
its('gid') { should eq 0 }
|
@@ -42,6 +37,21 @@ if os[:family] == 'aix'
|
|
42
37
|
its('gid') { should eq 2 }
|
43
38
|
end
|
44
39
|
|
40
|
+
describe group('noroot') do
|
41
|
+
it { should_not exist }
|
42
|
+
its('gid') { should eq nil }
|
43
|
+
end
|
44
|
+
elsif os.solaris?
|
45
|
+
describe group('root') do
|
46
|
+
it { should exist }
|
47
|
+
its('gid') { should eq 0 }
|
48
|
+
end
|
49
|
+
|
50
|
+
describe group('bin') do
|
51
|
+
it { should exist }
|
52
|
+
its('gid') { should eq 2 }
|
53
|
+
end
|
54
|
+
|
45
55
|
describe group('noroot') do
|
46
56
|
it { should_not exist }
|
47
57
|
its('gid') { should eq nil }
|
@@ -1,10 +1,12 @@
|
|
1
1
|
# encoding: utf-8
|
2
2
|
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
3
|
+
if os.linux?
|
4
|
+
# instead of `.with` or `.only_with` we recommend to use the `mount` resource
|
5
|
+
describe mount '/mnt/iso-disk' do
|
6
|
+
it { should be_mounted }
|
7
|
+
its('count') { should eq 1 }
|
8
|
+
its('device') { should eq '/root/empty.iso' }
|
9
|
+
its('type') { should eq 'iso9660' }
|
10
|
+
its('options') { should eq ['ro'] }
|
11
|
+
end
|
10
12
|
end
|
@@ -10,6 +10,22 @@ when 'aix'
|
|
10
10
|
it { should be_installed }
|
11
11
|
its('version') { should match /^(6|7)[.|\d]+\d$/ }
|
12
12
|
end
|
13
|
+
when 'solaris'
|
14
|
+
|
15
|
+
if os[:release] == '11'
|
16
|
+
pkg = 'system/file-system/zfs'
|
17
|
+
ver = /^0\.5.+$/
|
18
|
+
else
|
19
|
+
pkg = 'SUNWzfsr'
|
20
|
+
ver = /^11\.10.+$/
|
21
|
+
end
|
22
|
+
|
23
|
+
describe package(pkg) do
|
24
|
+
it { should be_installed }
|
25
|
+
its('version') { should match ver }
|
26
|
+
end
|
27
|
+
|
28
|
+
|
13
29
|
end
|
14
30
|
|
15
31
|
describe package('nginx') do
|
@@ -1,15 +1,21 @@
|
|
1
1
|
# encoding: utf-8
|
2
2
|
|
3
|
+
# check that ssh runs
|
3
4
|
if os.unix?
|
4
|
-
# check that ssh runs
|
5
5
|
describe port(22) do
|
6
6
|
it { should be_listening }
|
7
7
|
its('protocols') { should include('tcp') }
|
8
8
|
its('protocols') { should_not include('udp') }
|
9
|
-
its('processes') { should include 'sshd' }
|
10
9
|
end
|
11
10
|
|
12
11
|
describe port(65432) do
|
13
12
|
it { should_not be_listening }
|
14
13
|
end
|
15
14
|
end
|
15
|
+
|
16
|
+
# extra test for linux
|
17
|
+
if os.linux?
|
18
|
+
describe port(22) do
|
19
|
+
its('processes') { should include 'sshd' }
|
20
|
+
end
|
21
|
+
end
|