update kitchen container, activate all in travis

This commit is contained in:
Christoph Hartmann 2016-08-04 14:59:48 +02:00
parent 1c9d998afd
commit 93a068b8fa
8 changed files with 59 additions and 27 deletions

View file

@ -21,10 +21,6 @@ platforms:
- name: ubuntu-14.04 - name: ubuntu-14.04
driver: driver:
image: ubuntu:14.04 image: ubuntu:14.04
- name: ubuntu-15.10
driver:
image: ubuntu:15.10
pid_one_command: /bin/systemd
- name: ubuntu-16.04 - name: ubuntu-16.04
driver: driver:
image: ubuntu:16.04 image: ubuntu:16.04
@ -34,37 +30,36 @@ platforms:
- name: centos-6.6 - name: centos-6.6
driver: driver:
image: centos:6.6 image: centos:6.6
- name: centos-6.7 - name: centos-6.8
driver: driver:
image: centos:6.7 image: centos:6.8
intermediate_instructions: intermediate_instructions:
- RUN yum install -y initscripts - RUN yum install -y initscripts
- name: centos-7 - name: centos-7
driver: driver:
image: centos:7 image: centos:7
pid_one_command: /usr/lib/systemd/systemd pid_one_command: /usr/lib/systemd/systemd
- name: oracle-6.6
driver:
image: oraclelinux:6.6
- name: oracle-6.7 - name: oracle-6.7
driver: driver:
image: oraclelinux:6.7 image: oraclelinux:6.7
- name: oracle-7.1 - name: oracle-7.2
driver: driver:
image: oraclelinux:7.1 image: oraclelinux:7.2
pid_one_command: /usr/lib/systemd/systemd pid_one_command: /usr/lib/systemd/systemd
- name: debian-7 - name: debian-7
driver: driver:
image: debian:7 image: debian:7.11
intermediate_instructions: intermediate_instructions:
- RUN /usr/bin/apt-get update - RUN /usr/bin/apt-get update
- RUN /usr/bin/apt-get install -y procps # running it within the chef recipe is too late :-(
- RUN /usr/bin/apt-get install -y procps lsb-release
- name: debian-8 - name: debian-8
driver: driver:
image: debian:8 image: debian:8.5
intermediate_instructions: intermediate_instructions:
- RUN /usr/bin/apt-get update - RUN /usr/bin/apt-get update
- RUN /usr/bin/apt-get install -y procps # running it within the chef recipe is too late :-(
- RUN /usr/bin/apt-get install -y procps lsb-release
pid_one_command: /bin/systemd pid_one_command: /bin/systemd
suites: suites:

View file

@ -26,10 +26,39 @@ matrix:
bundler_args: "--without guard tools" bundler_args: "--without guard tools"
script: bundle exec rake $SUITE script: bundle exec rake $SUITE
env: SUITE=test:integration OS=default-ubuntu-1204 DOCKER=true env: SUITE=test:integration OS=default-ubuntu-1204 DOCKER=true
- rvm: 2.2
bundler_args: "--without guard tools"
script: bundle exec rake $SUITE
env: SUITE=test:integration OS='default-ubuntu-1404' DOCKER=true
- rvm: 2.2 - rvm: 2.2
bundler_args: "--without guard tools" bundler_args: "--without guard tools"
script: bundle exec rake $SUITE script: bundle exec rake $SUITE
env: SUITE=test:integration OS='default-ubuntu-1604' DOCKER=true env: SUITE=test:integration OS='default-ubuntu-1604' DOCKER=true
- rvm: 2.2
bundler_args: "--without guard tools"
script: bundle exec rake $SUITE
env: SUITE=test:integration OS='default-centos-68' DOCKER=true
- rvm: 2.2
bundler_args: "--without guard tools"
script: bundle exec rake $SUITE
env: SUITE=test:integration OS='default-centos-7' DOCKER=true
- rvm: 2.2
bundler_args: "--without guard tools"
script: bundle exec rake $SUITE
env: SUITE=test:integration OS='default-debian-7' DOCKER=true
- rvm: 2.2
bundler_args: "--without guard tools"
script: bundle exec rake $SUITE
env: SUITE=test:integration OS='default-debian-8' DOCKER=true
- rvm: 2.2
bundler_args: "--without guard tools"
script: bundle exec rake $SUITE
env: SUITE=test:integration OS='default-oracle-67' DOCKER=true
- rvm: 2.2
bundler_args: "--without guard tools"
script: bundle exec rake $SUITE
env: SUITE=test:integration OS='default-oracle-72' DOCKER=true
deploy: deploy:
provider: rubygems provider: rubygems
on: on:

View file

@ -5,13 +5,13 @@
# add nginx apt repository # add nginx apt repository
case node['platform'] case node['platform']
when 'ubuntu' when 'ubuntu'
include_recipe('apt') # use ppa
apt_repository 'nginx' do apt_repository 'nginx' do
uri 'ppa:nginx/stable' uri 'ppa:nginx/stable'
distribution node['lsb']['codename'] distribution node['lsb']['codename']
end end
when 'debian' when 'debian'
include_recipe('apt') # use plain repo
apt_repository 'nginx' do apt_repository 'nginx' do
uri 'http://nginx.org/packages/debian' uri 'http://nginx.org/packages/debian'
distribution node['lsb']['codename'] distribution node['lsb']['codename']

View file

@ -4,6 +4,8 @@
# #
# prepare all operating systems with the required configuration # prepare all operating systems with the required configuration
# container preparation
include_recipe('os_prepare::prep_container')
# basic tests # basic tests
include_recipe('os_prepare::file') include_recipe('os_prepare::file')

View file

@ -5,9 +5,8 @@
# installs everything to do the package test # installs everything to do the package test
case node['platform'] case node['platform']
when 'ubuntu' when 'ubuntu', 'debian'
include_recipe('apt') include_recipe('apt')
package 'curl' package 'curl'
when 'rhel', 'centos', 'fedora' when 'rhel', 'centos', 'fedora'
include_recipe('yum') include_recipe('yum')

View file

@ -0,0 +1,15 @@
# encoding: utf-8
# author: Christoph Hartmann
# author: Dominik Richter
#
# prepares container for normal use :-)
# install docker pre-conditions
if ['ubuntu', 'debian'].include?(node['platform'])
include_recipe('apt')
# if package lsb-release & procps is not installed
# chef returns an empty node['lsb']['codename']
package("lsb-release")
package("procps")
end

View file

@ -29,11 +29,6 @@ elsif os[:family] == 'debian'
it { should be_enabled } it { should be_enabled }
end end
describe apt('http://nginx.org/packages/debian') do
it { should exist }
it { should be_enabled }
end
describe apt('https://deb.nodesource.com/node_4.x/dists/precise/') do describe apt('https://deb.nodesource.com/node_4.x/dists/precise/') do
it { should_not exist } it { should_not exist }
it { should_not be_enabled } it { should_not be_enabled }

View file

@ -11,7 +11,6 @@ when 'aix'
its('version') { should match /^(6|7)[.|\d]+\d$/ } its('version') { should match /^(6|7)[.|\d]+\d$/ }
end end
when 'solaris' when 'solaris'
if os[:release] == '11' if os[:release] == '11'
pkg = 'system/file-system/zfs' pkg = 'system/file-system/zfs'
ver = /^0\.5.+$/ ver = /^0\.5.+$/
@ -24,8 +23,6 @@ when 'solaris'
it { should be_installed } it { should be_installed }
its('version') { should match ver } its('version') { should match ver }
end end
end end
describe package('nginx') do describe package('nginx') do