Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Sample chef cookbook .travis.yml file
sudo: required
dist: trusty
addons:
apt:
sources:
- chef-current-trusty
packages:
- chefdk
install: echo "skip bundle install"
branches:
only:
- master
services: docker
env:
matrix:
- INSTANCE=test-centos-6
- INSTANCE=test-centos-7
- INSTANCE=test-ubuntu-1404
- INSTANCE=test-ubuntu-1604
- INSTANCE=test-ubuntu-1804
before_script:
- sudo iptables -L DOCKER || ( echo "DOCKER iptables chain missing" ; sudo iptables -N DOCKER )
- eval "$(/opt/chefdk/bin/chef shell-init bash)"
- chef --version
- cookstyle --version
- foodcritic --version
script: KITCHEN_LOCAL_YAML=.kitchen.dokken.yml kitchen verify ${INSTANCE}
after_script:
- docker images
- docker ps -a
- cat .kitchen/logs/kitchen.log
matrix:
include:
- script:
- delivery local verify
env: UNIT_AND_LINT=1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.