Sha256: fb26452ab941a1a52b47d9b3292f7287b6cbcefabbbbc0e90e211dcd67617b04

Contents?: true

Size: 866 Bytes

Versions: 2

Compression:

Stored size: 866 Bytes

Contents

describe processes('docker') do
  its('users') { should eq ['root'] }
  its('states') { should include 'Ssl' }
end

describe command('docker ps') do
  its(:exit_status) { should eq 0 }
  its(:stdout) { should match(/^CONTAINER/) }
end

# Test for /var/log/docker.log for all non-systemd platforms
systemd = true
systemd = false if os[:family] == 'redhat' && os[:release].nil? # amazon?
systemd = false if os[:family] == 'redhat' && os[:release].to_i < 7
systemd = false if os[:family] == 'ubuntu' && os[:release].to_f < 15.04

unless systemd
  describe file('/var/log/docker.log') do
    it { should be_file }
    it { should be_mode 0644 }
  end
end

describe kernel_parameter('net.ipv4.ip_forward') do
  its(:value) { should eq 1 }
end

describe kernel_parameter('net.ipv6.conf.all.forwarding') do
  its(:value) { should eq 1 }
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
chef-12.8.1 acceptance/top-cookbooks/test_run/docker/test/integration/service-systemd/inspec/assert_functioning_spec.rb
chef-12.8.1-universal-mingw32 acceptance/top-cookbooks/test_run/docker/test/integration/service-systemd/inspec/assert_functioning_spec.rb