-
-
Notifications
You must be signed in to change notification settings - Fork 243
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 #337 from johnbellone/integration-docker
Add travis and docker integration tests.
- Loading branch information
Showing
12 changed files
with
118 additions
and
48 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1 @@ | ||
--color | ||
--default-path test/spec | ||
--default-path test/spec --color |
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,14 +1,47 @@ | ||
--- | ||
language: ruby | ||
sudo: required | ||
dist: trusty | ||
language: generic | ||
cache: bundler | ||
sudo: false | ||
addons: | ||
apt: | ||
sources: | ||
- chef-current-trusty | ||
packages: | ||
- chefdk | ||
services: docker | ||
env: | ||
matrix: | ||
- INSTANCE=default-centos-7 | ||
- INSTANCE=default-centos-6 | ||
- INSTANCE=default-ubuntu-1604 | ||
- INSTANCE=default-ubuntu-1404 | ||
- INSTANCE=default-ubuntu-1204 | ||
- INSTANCE=default-debian-8 | ||
- INSTANCE=default-debian-7 | ||
before_script: | ||
# https://github.com/zuazo/kitchen-in-travis-native/issues/1#issuecomment-142230889 | ||
- sudo iptables -L DOCKER || ( echo "DOCKER iptables chain missing" ; sudo iptables -N DOCKER ) | ||
- eval "$(/opt/chefdk/bin/chef shell-init bash)" | ||
- /opt/chefdk/embedded/bin/chef gem install kitchen-dokken | ||
- /opt/chefdk/embedded/bin/chef gem install kitchen-verifier-serverspec | ||
- /opt/chefdk/embedded/bin/chef --version | ||
- /opt/chefdk/embedded/bin/cookstyle --version | ||
- /opt/chefdk/embedded/bin/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: /opt/chefdk/embedded/bin/cookstyle | ||
env: COOKSTYLE=1 | ||
- script: /opt/chefdk/embedded/bin/foodcritic . --exclude spec -f any | ||
env: FOODCRITIC=1 | ||
- script: | ||
- bundle install | ||
- /opt/chefdk/embedded/bin/rspec --color --default-path test/spec | ||
env: CHEFSPEC=1 | ||
notifications: | ||
slack: bloomberg-rnd:BvYmxrV9xj902XWTRNrkLNkR | ||
script: bundle exec rake travis | ||
rvm: | ||
- 2.2 | ||
branches: | ||
only: | ||
- master | ||
matrix: | ||
fast_finish: true |
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 |
---|---|---|
|
@@ -13,6 +13,7 @@ end | |
group :unit, :integration do | ||
gem 'chef-dk' | ||
gem 'chefspec' | ||
gem 'rubyzip' | ||
gem 'serverspec' | ||
end | ||
|
||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,8 @@ | ||
default_source :community | ||
default_source :chef_repo, '..' | ||
cookbook 'consul', path: '../../..' | ||
run_list 'consul::default', "consul_spec::#{name}" | ||
named_run_list :rhel, 'yum::default', run_list | ||
run_list 'sudo::default', 'consul::default', "consul_spec::#{name}" | ||
named_run_list :centos, 'yum::default', 'yum-centos::default', run_list | ||
named_run_list :debian, 'apt::default', run_list | ||
named_run_list :freebsd, 'freebsd::default', run_list | ||
named_run_list :windows, 'windows::default', run_list |
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