Skip to content

Instantly share code, notes, and snippets.

@nandotorres
Last active December 10, 2016 20:16
Show Gist options
  • Save nandotorres/64530639b83fd1cad9864a924d9b01af to your computer and use it in GitHub Desktop.
Save nandotorres/64530639b83fd1cad9864a924d9b01af to your computer and use it in GitHub Desktop.
kitchen configuration file to work with kitchen-docker.yml
driver:
name: docker
use_sudo: false
privileged: true
provisioner:
name: chef_solo
always_update_cookbooks: true
verifier:
name: inspec
platforms:
- name: ubuntu-16.04
driver_config:
image: ubuntu:16.04
platform: ubuntu
privileged: true
provision_command:
- apt-get -y install dbus net-tools
- echo "SSHD_OPTS='-o UseDNS=no -o UsePAM=no -o PasswordAuthentication=yes -o UsePrivilegeSeparation=no -o PidFile=/tmp/sshd.pid'" > /etc/default/ssh
- ln -s /lib/systemd/system/systemd-logind.service /etc/systemd/system/multi-user.target.wants/systemd-logind.service
- mkdir /etc/systemd/system/sockets.target.wants/
- ln -s /lib/systemd/system/dbus.socket /etc/systemd/system/sockets.target.wants/dbus.socket
- systemctl set-default multi-user.target
run_command: /sbin/init
cap_add:
- ALL
- SYS_ADMIN
- NET_ADMIN
- NET_BIND_SERVICE
- NET_BROADCAST
suites:
- name: default
run_list:
- recipe[techtalk::default]
verifier:
inspec_tests:
- test/recipes
attributes:
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment