ci(travis): update test matrix
This commit is contained in:
parent
b2bcb4c998
commit
cd58d3b7ad
66
.travis.yml
66
.travis.yml
@ -1,9 +1,3 @@
|
|||||||
stages:
|
|
||||||
- test
|
|
||||||
- commitlint
|
|
||||||
- name: release
|
|
||||||
if: branch = master AND type != pull_request
|
|
||||||
|
|
||||||
sudo: required
|
sudo: required
|
||||||
cache: bundler
|
cache: bundler
|
||||||
language: ruby
|
language: ruby
|
||||||
@ -12,55 +6,25 @@ services:
|
|||||||
- docker
|
- docker
|
||||||
|
|
||||||
before_install:
|
before_install:
|
||||||
- gem install bundle
|
- gem install bundler
|
||||||
- bundle install
|
- bundle install
|
||||||
|
|
||||||
# Make sure the instances listed below match up with
|
|
||||||
# the `platforms` defined in `kitchen.yml`
|
|
||||||
env:
|
env:
|
||||||
matrix:
|
matrix:
|
||||||
- INSTANCE: default-debian-9
|
- INSTANCE: v2019-2-py3-debian-9
|
||||||
- INSTANCE: default-debian-8
|
- INSTANCE: v2019-2-py3-ubuntu-1804
|
||||||
- INSTANCE: default-ubuntu-1804
|
- INSTANCE: v2019-2-py3-centos-7
|
||||||
- INSTANCE: default-ubuntu-1604
|
- INSTANCE: v2019-2-py2-fedora-29
|
||||||
- INSTANCE: default-centos-7
|
|
||||||
# - INSTANCE: default-centos-6
|
- INSTANCE: v2018-3-py2-debian-8
|
||||||
- INSTANCE: default-fedora
|
- INSTANCE: v2018-3-py2-ubuntu-1604
|
||||||
- INSTANCE: default-opensuse-leap-salt-minion
|
- INSTANCE: v2018-3-py2-bootstrap-centos-6
|
||||||
|
- INSTANCE: v2018-3-py2-forced-version-fedora-28
|
||||||
|
- INSTANCE: v2018-3-py2-opensuse-423
|
||||||
|
|
||||||
|
- INSTANCE: v2017-7-py2-debian-8
|
||||||
|
- INSTANCE: v2017-7-py2-ubuntu-1604
|
||||||
|
- INSTANCE: v2017-7-py2-bootstrap-centos-6
|
||||||
|
|
||||||
script:
|
script:
|
||||||
- bundle exec kitchen verify ${INSTANCE}
|
- bundle exec kitchen verify ${INSTANCE}
|
||||||
|
|
||||||
jobs:
|
|
||||||
include:
|
|
||||||
# Define the commitlint stage
|
|
||||||
- stage: commitlint
|
|
||||||
language: node_js
|
|
||||||
node_js: lts/*
|
|
||||||
before_install: skip
|
|
||||||
script:
|
|
||||||
- npm install @commitlint/config-conventional -D
|
|
||||||
- npm install @commitlint/travis-cli -D
|
|
||||||
- commitlint-travis
|
|
||||||
# Define the release stage that runs semantic-release
|
|
||||||
- stage: release
|
|
||||||
language: node_js
|
|
||||||
node_js: lts/*
|
|
||||||
before_install: skip
|
|
||||||
script:
|
|
||||||
# Update `AUTHORS.md`
|
|
||||||
- export MAINTAINER_TOKEN=${GH_TOKEN}
|
|
||||||
- go get github.com/myii/maintainer
|
|
||||||
- maintainer contributor
|
|
||||||
|
|
||||||
# Install all dependencies required for `semantic-release`
|
|
||||||
- npm install @semantic-release/changelog@3 -D
|
|
||||||
- npm install @semantic-release/exec@3 -D
|
|
||||||
- npm install @semantic-release/git@7 -D
|
|
||||||
deploy:
|
|
||||||
provider: script
|
|
||||||
skip_cleanup: true
|
|
||||||
script:
|
|
||||||
# Run `semantic-release`
|
|
||||||
- npx semantic-release@15
|
|
||||||
|
|
||||||
|
232
kitchen.yml
232
kitchen.yml
@ -1,104 +1,200 @@
|
|||||||
# -*- coding: utf-8 -*-
|
|
||||||
# vim: ft=yaml
|
|
||||||
---
|
---
|
||||||
# For help on this file's format, see https://kitchen.ci/
|
|
||||||
driver:
|
driver:
|
||||||
name: docker
|
name: docker
|
||||||
|
|
||||||
driver_config:
|
|
||||||
use_sudo: false
|
use_sudo: false
|
||||||
privileged: true
|
privileged: true
|
||||||
provision_command: mkdir -p /run/sshd
|
provision_command: mkdir -p /run/sshd
|
||||||
|
run_command: /lib/systemd/systemd
|
||||||
|
|
||||||
# Make sure the platforms listed below match up with
|
|
||||||
# the `env.matrix` instances defined in `.travis.yml`
|
|
||||||
platforms:
|
platforms:
|
||||||
# The `run_command` used for each platform is required to
|
# Latest distros
|
||||||
# test `systemd` services in docker
|
|
||||||
- name: debian-9
|
- name: debian-9
|
||||||
driver_config:
|
|
||||||
image: debian:9
|
|
||||||
run_command: /lib/systemd/systemd
|
|
||||||
provision_command:
|
|
||||||
- apt-get update && apt-get install -y udev
|
|
||||||
- name: debian-8
|
|
||||||
driver_config:
|
|
||||||
image: debian:8
|
|
||||||
run_command: /lib/systemd/systemd
|
|
||||||
provision_command:
|
|
||||||
- apt-get update && apt-get install -y udev
|
|
||||||
- name: ubuntu-18.04
|
- name: ubuntu-18.04
|
||||||
driver_config:
|
|
||||||
image: ubuntu:18.04
|
|
||||||
run_command: /lib/systemd/systemd
|
|
||||||
provision_command:
|
|
||||||
- apt-get update && apt-get install -y udev
|
|
||||||
- name: ubuntu-16.04
|
|
||||||
driver_config:
|
|
||||||
image: ubuntu:16.04
|
|
||||||
run_command: /lib/systemd/systemd
|
|
||||||
provision_command:
|
|
||||||
- apt-get update && apt-get install -y udev
|
|
||||||
- name: centos-7
|
- name: centos-7
|
||||||
driver_config:
|
- name: fedora-29
|
||||||
image: centos:7
|
- name: opensuse-42.3
|
||||||
run_command: /usr/lib/systemd/systemd
|
driver:
|
||||||
# - name: centos-6
|
|
||||||
# driver_config:
|
|
||||||
# image: centos:6
|
|
||||||
# run_command: /usr/lib/systemd/systemd
|
|
||||||
- name: fedora
|
|
||||||
driver_config:
|
|
||||||
image: fedora
|
|
||||||
run_command: /usr/lib/systemd/systemd
|
run_command: /usr/lib/systemd/systemd
|
||||||
provision_command:
|
provision_command:
|
||||||
- yum -y update && yum -y install udev
|
|
||||||
# As of February 2019, there have been problems getting `opensuse` to work:
|
|
||||||
# * `opensuse` is deprecated
|
|
||||||
# * `opensuse/leap` grabs `15.x`, which doesn't run the `inspec` tests
|
|
||||||
# * `opensuse/tumbleweed` doesn't install `salt-minion`
|
|
||||||
# * `opensuse/leap:42.3` does work
|
|
||||||
# * `opensuse/salt-minion` uses `42.3` with `salt-minion` pre-installed
|
|
||||||
- name: opensuse-leap-salt-minion
|
|
||||||
driver_config:
|
|
||||||
image: opensuse/salt-minion
|
|
||||||
run_command: /usr/lib/systemd/systemd
|
|
||||||
provision_command:
|
|
||||||
- zypper refresh && zypper install -y udev
|
|
||||||
- systemctl enable sshd.service
|
- systemctl enable sshd.service
|
||||||
- cat /etc/os-release
|
|
||||||
|
# Previous distros
|
||||||
|
- name: debian-8
|
||||||
|
- name: ubuntu-16.04
|
||||||
|
- name: fedora-28
|
||||||
|
# centos-6 guest fails on Debian hosts due to vsyscall issues, see
|
||||||
|
# https://hub.docker.com/_/centos, "A note about vsyscall"
|
||||||
|
- name: centos-6
|
||||||
|
driver:
|
||||||
|
run_command: /sbin/init
|
||||||
|
|
||||||
provisioner:
|
provisioner:
|
||||||
name: salt_solo
|
name: salt_solo
|
||||||
log_level: debug
|
log_level: info
|
||||||
require_chef: false
|
|
||||||
salt_version: latest
|
salt_version: latest
|
||||||
|
require_chef: false
|
||||||
formula: nginx
|
formula: nginx
|
||||||
salt_copy_filter:
|
salt_copy_filter:
|
||||||
- .kitchen
|
- .kitchen
|
||||||
- .git
|
- .git
|
||||||
pillars_from_files:
|
state_top:
|
||||||
nginx.sls: test/salt/default/pillar/nginx.sls
|
base:
|
||||||
|
'*':
|
||||||
|
- nginx.ng
|
||||||
pillars:
|
pillars:
|
||||||
top.sls:
|
top.sls:
|
||||||
base:
|
base:
|
||||||
'*':
|
'*':
|
||||||
- nginx
|
- nginx
|
||||||
state_top:
|
pillars_from_files:
|
||||||
base:
|
nginx.sls: test/salt/default/pillar/nginx.sls
|
||||||
'*':
|
|
||||||
- nginx.ng
|
|
||||||
|
|
||||||
verifier:
|
verifier:
|
||||||
# https://www.inspec.io/
|
|
||||||
name: inspec
|
name: inspec
|
||||||
sudo: true
|
sudo: true
|
||||||
# cli, documentation, html, progress, json, json-min, json-rspec, junit
|
|
||||||
reporter:
|
reporter:
|
||||||
- cli
|
- cli
|
||||||
inspec_tests:
|
|
||||||
- path: test/integration/default
|
|
||||||
|
|
||||||
suites:
|
suites:
|
||||||
- name: default
|
# Latest distros, latest salt, python3
|
||||||
|
# These distros have py3 packages available in salt's repo
|
||||||
|
- name: v2019-2-py3
|
||||||
|
includes:
|
||||||
|
- debian-9
|
||||||
|
- ubuntu-18.04
|
||||||
|
- centos-7
|
||||||
|
provisioner:
|
||||||
|
# If we don't force bootstrapping with python3, centos bootstraps using python2
|
||||||
|
# and then, when switching the repo to python3 and tries to install
|
||||||
|
# the packages, complains with
|
||||||
|
# Downloading packages:
|
||||||
|
# https://repo.saltstack.com/py3/re.........rpm: [Errno -1] Package does not
|
||||||
|
# match intended download. Suggestion: run yum --enablerepo=saltstack clean metadata
|
||||||
|
salt_bootstrap_options: -X -x python3 -d git %s
|
||||||
|
salt_version: '2019.2'
|
||||||
|
pillars:
|
||||||
|
salt.sls:
|
||||||
|
salt:
|
||||||
|
release: '2019.2'
|
||||||
|
py_ver: 'py3'
|
||||||
|
|
||||||
|
verifier:
|
||||||
|
inspec_tests:
|
||||||
|
#- path: test/integration/2019-2
|
||||||
|
- path: test/integration/default
|
||||||
|
|
||||||
|
# Latest distros, latest salt, python2
|
||||||
|
# Fedora ships updated py2 versions in their own repos
|
||||||
|
- name: v2019-2-py2
|
||||||
|
includes:
|
||||||
|
- fedora-29
|
||||||
|
provisioner:
|
||||||
|
salt_version: '2019.2'
|
||||||
|
pillars:
|
||||||
|
salt.sls:
|
||||||
|
salt:
|
||||||
|
release: '2019.2'
|
||||||
|
py_ver: 'py2'
|
||||||
|
|
||||||
|
verifier:
|
||||||
|
inspec_tests:
|
||||||
|
#- path: test/integration/2019-2
|
||||||
|
- path: test/integration/default
|
||||||
|
|
||||||
|
# Previous distros, previous salt, python2
|
||||||
|
- name: v2018-3-py2
|
||||||
|
includes:
|
||||||
|
- debian-8
|
||||||
|
- ubuntu-16.04
|
||||||
|
- opensuse-42.3
|
||||||
|
provisioner:
|
||||||
|
# We require an old version of salt in the provisioner or,
|
||||||
|
# the salt formula fails to downgrade to the desired version to test
|
||||||
|
salt_version: '2018.3'
|
||||||
|
pillars:
|
||||||
|
salt.sls:
|
||||||
|
salt:
|
||||||
|
release: '2018.3'
|
||||||
|
py_ver: 'py2'
|
||||||
|
verifier:
|
||||||
|
inspec_tests:
|
||||||
|
#- path: test/integration/2018-3
|
||||||
|
- path: test/integration/default
|
||||||
|
|
||||||
|
# centos-6 ships with python2.6, so it requires extra bootstrapping parameters
|
||||||
|
# to install python2.7
|
||||||
|
- name: v2018-3-py2-bootstrap
|
||||||
|
includes:
|
||||||
|
- centos-6
|
||||||
|
provisioner:
|
||||||
|
salt_bootstrap_options: -X -d stable %s
|
||||||
|
salt_version: '2018.3'
|
||||||
|
pillars:
|
||||||
|
salt.sls:
|
||||||
|
salt:
|
||||||
|
release: '2018.3'
|
||||||
|
py_ver: 'py2'
|
||||||
|
verifier:
|
||||||
|
inspec_tests:
|
||||||
|
#- path: test/integration/2018-3
|
||||||
|
- path: test/integration/default
|
||||||
|
|
||||||
|
# To tests fedora 28 & salt v2018.2, we need to force the package version
|
||||||
|
# otherwise the image, which includes the 'updates' repo, will install 2019.2
|
||||||
|
- name: v2018-3-py2-forced-version
|
||||||
|
includes:
|
||||||
|
- fedora-28
|
||||||
|
provisioner:
|
||||||
|
# We require an old version of salt in the provisioner or,
|
||||||
|
# the salt formula fails to downgrade to the desired version to test
|
||||||
|
salt_version: '2018.3'
|
||||||
|
pillars:
|
||||||
|
salt.sls:
|
||||||
|
salt:
|
||||||
|
release: '2018.3'
|
||||||
|
py_ver: 'py2'
|
||||||
|
version: '2018.3.0-1.fc28'
|
||||||
|
|
||||||
|
verifier:
|
||||||
|
inspec_tests:
|
||||||
|
#- path: test/integration/2018-3
|
||||||
|
- path: test/integration/default
|
||||||
|
|
||||||
|
# Previous distros, oldest salt, python2
|
||||||
|
- name: v2017-7-py2
|
||||||
|
includes:
|
||||||
|
- debian-8
|
||||||
|
- ubuntu-16.04
|
||||||
|
provisioner:
|
||||||
|
# We require an old version of salt in the provisioner or,
|
||||||
|
# the salt formula fails to downgrade to the desired version to test
|
||||||
|
salt_version: '2017.7'
|
||||||
|
pillars:
|
||||||
|
salt.sls:
|
||||||
|
salt:
|
||||||
|
release: '2017.7'
|
||||||
|
py_ver: 'py2'
|
||||||
|
verifier:
|
||||||
|
inspec_tests:
|
||||||
|
#- path: test/integration/2017-7
|
||||||
|
- path: test/integration/default
|
||||||
|
|
||||||
|
# centos-6 ships with python2.6, so it requires extra bootstrapping parameters
|
||||||
|
# to install python2.7
|
||||||
|
- name: v2017-7-py2-bootstrap
|
||||||
|
includes:
|
||||||
|
- centos-6
|
||||||
|
provisioner:
|
||||||
|
# As centos-6 ships with python2.6, we use the bootstrapper to install python2.7
|
||||||
|
salt_bootstrap_options: -X -d stable %s
|
||||||
|
salt_version: '2017.7'
|
||||||
|
pillars:
|
||||||
|
salt.sls:
|
||||||
|
salt:
|
||||||
|
release: '2017.7'
|
||||||
|
py_ver: 'py2'
|
||||||
|
verifier:
|
||||||
|
inspec_tests:
|
||||||
|
#- path: test/integration/2017-7
|
||||||
|
- path: test/integration/default
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user