|
|
@@ -1,32 +1,103 @@ |
|
|
|
<% |
|
|
|
distrib, infos = ENV.fetch('DISTRIB', 'debian:stretch/9').split(':') |
|
|
|
codename, version = infos.split('/') |
|
|
|
%> |
|
|
|
# -*- coding: utf-8 -*- |
|
|
|
# vim: ft=yaml |
|
|
|
--- |
|
|
|
# For help on this file's format, see https://kitchen.ci/ |
|
|
|
driver: |
|
|
|
name: docker |
|
|
|
use_sudo: false |
|
|
|
privileged: true |
|
|
|
run_command: /lib/systemd/systemd |
|
|
|
|
|
|
|
provisioner: |
|
|
|
name: salt_solo |
|
|
|
formula: ufw |
|
|
|
# Make sure the platforms listed below match up with |
|
|
|
# the `env.matrix` instances defined in `.travis.yml` |
|
|
|
platforms: |
|
|
|
## SALT 2019.2 |
|
|
|
- name: debian-9-2019-2-py3 |
|
|
|
driver: |
|
|
|
image: netmanagers/salt-2019.2-py3:debian-9 |
|
|
|
provision_command: |
|
|
|
- apt-get update && apt-get install -y locales |
|
|
|
- echo "en_US.UTF-8 UTF-8" >> /etc/locale.gen |
|
|
|
- locale-gen en_US.UTF-8 |
|
|
|
- name: ubuntu-1804-2019-2-py3 |
|
|
|
driver: |
|
|
|
image: netmanagers/salt-2019.2-py3:ubuntu-18.04 |
|
|
|
- name: centos-7-2019-2-py3 |
|
|
|
driver: |
|
|
|
image: netmanagers/salt-2019.2-py3:centos-7 |
|
|
|
- name: fedora-29-2019-2-py3 |
|
|
|
driver: |
|
|
|
image: netmanagers/salt-2019.2-py3:fedora-29 |
|
|
|
- name: opensuse-leap-15-2019-2-py3 |
|
|
|
driver: |
|
|
|
image: netmanagers/salt-2019.2-py3:opensuse-leap-15 |
|
|
|
run_command: /usr/lib/systemd/systemd |
|
|
|
|
|
|
|
# Install Salt from official repositories |
|
|
|
salt_install: apt |
|
|
|
salt_version: latest |
|
|
|
salt_apt_repo: https://repo.saltstack.com/apt/<%= distrib %>/<%= version %>/amd64 |
|
|
|
salt_apt_repo_key: https://repo.saltstack.com/apt/<%= distrib %>/<%= version %>/amd64/latest/SALTSTACK-GPG-KEY.pub |
|
|
|
## SALT 2018.3 |
|
|
|
- name: debian-9-2018-3-py2 |
|
|
|
driver: |
|
|
|
image: netmanagers/salt-2018.3-py2:debian-9 |
|
|
|
provision_command: |
|
|
|
- apt-get update && apt-get install -y locales |
|
|
|
- echo "en_US.UTF-8 UTF-8" >> /etc/locale.gen |
|
|
|
- locale-gen en_US.UTF-8 |
|
|
|
- name: ubuntu-1604-2018-3-py2 |
|
|
|
driver: |
|
|
|
image: netmanagers/salt-2018.3-py2:ubuntu-16.04 |
|
|
|
- name: centos-7-2018-3-py2 |
|
|
|
driver: |
|
|
|
image: netmanagers/salt-2018.3-py2:centos-7 |
|
|
|
- name: fedora-29-2018-3-py2 |
|
|
|
driver: |
|
|
|
image: netmanagers/salt-2018.3-py2:fedora-29 |
|
|
|
# TODO: Use this when fixed instead of `opensuse-leap-42` |
|
|
|
# Ref: https://github.com/netmanagers/salt-image-builder/issues/2 |
|
|
|
# - name: opensuse-leap-15-2018-3-py2 |
|
|
|
# driver: |
|
|
|
# image: netmanagers/salt-2018.3-py2:opensuse-leap-15 |
|
|
|
# run_command: /usr/lib/systemd/systemd |
|
|
|
- name: opensuse-leap-42-2018-3-py2 |
|
|
|
driver: |
|
|
|
image: netmanagers/salt-2018.3-py2:opensuse-leap-42 |
|
|
|
run_command: /usr/lib/systemd/systemd |
|
|
|
|
|
|
|
# Don't install Chef |
|
|
|
require_chef: false |
|
|
|
## SALT 2017.7 |
|
|
|
- name: debian-8-2017-7-py2 |
|
|
|
driver: |
|
|
|
image: netmanagers/salt-2017.7-py2:debian-8 |
|
|
|
provision_command: |
|
|
|
- apt-get update && apt-get install -y locales |
|
|
|
- echo "en_US.UTF-8 UTF-8" >> /etc/locale.gen |
|
|
|
- locale-gen en_US.UTF-8 |
|
|
|
- name: ubuntu-1604-2017-7-py2 |
|
|
|
driver: |
|
|
|
image: netmanagers/salt-2017.7-py2:ubuntu-16.04 |
|
|
|
- name: centos-6-2017-7-py2 |
|
|
|
driver: |
|
|
|
image: netmanagers/salt-2017.7-py2:centos-6 |
|
|
|
run_command: /sbin/init |
|
|
|
run_options: -v /lib/modules:/lib/modules:ro |
|
|
|
- name: fedora-28-2017-7-py2 |
|
|
|
driver: |
|
|
|
image: netmanagers/salt-2017.7-py2:fedora-28 |
|
|
|
- name: opensuse-leap-42-2017-7-py2 |
|
|
|
driver: |
|
|
|
image: netmanagers/salt-2017.7-py2:opensuse-leap-42 |
|
|
|
run_command: /usr/lib/systemd/systemd |
|
|
|
|
|
|
|
# Configure Salt |
|
|
|
provisioner: |
|
|
|
name: salt_solo |
|
|
|
log_level: info |
|
|
|
salt_install: none |
|
|
|
require_chef: false |
|
|
|
formula: ufw |
|
|
|
salt_copy_filter: |
|
|
|
- .kitchen |
|
|
|
- .git |
|
|
|
state_top: |
|
|
|
base: |
|
|
|
'*': |
|
|
|
- ufw |
|
|
|
|
|
|
|
pillars: |
|
|
|
top.sls: |
|
|
|
base: |
|
|
@@ -67,21 +138,15 @@ provisioner: |
|
|
|
protocol: tcp |
|
|
|
comment: Allow HTTPS |
|
|
|
|
|
|
|
platforms: |
|
|
|
- name: <%= distrib %>-<%= codename %> |
|
|
|
driver_config: |
|
|
|
image: "<%= distrib %>:<%= codename %>" |
|
|
|
platform: <%= distrib %> |
|
|
|
provision_command: |
|
|
|
- apt-get update && apt-get install -y locales |
|
|
|
- echo "en_US.UTF-8 UTF-8" >> /etc/locale.gen |
|
|
|
- locale-gen en_US.UTF-8 |
|
|
|
run_command: /lib/systemd/systemd |
|
|
|
|
|
|
|
verifier: |
|
|
|
# https://www.inspec.io/ |
|
|
|
name: inspec |
|
|
|
sudo: true |
|
|
|
# cli, documentation, html, progress, json, json-min, json-rspec, junit |
|
|
|
reporter: |
|
|
|
- progress |
|
|
|
- cli |
|
|
|
inspec_tests: |
|
|
|
- path: test/integration/default |
|
|
|
|
|
|
|
suites: |
|
|
|
- name: ufw |
|
|
|
- name: default |