Skip to content

Commit 2a54616

Browse files
authored
Merge pull request #262 from myii/chore/add-new-ci-matrix
Replace `serverspec` with `inspec` tests via. new CI matrix (inc. `semantic-release`)
2 parents 29cd2d8 + 7d3aa19 commit 2a54616

20 files changed

+1508
-86
lines changed

Diff for: .gitignore

+110-3
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,110 @@
1-
.kitchen/
2-
*.swp
3-
*.swo
1+
# Byte-compiled / optimized / DLL files
2+
__pycache__/
3+
*.py[cod]
4+
*$py.class
5+
6+
# C extensions
7+
*.so
8+
9+
# Distribution / packaging
10+
.Python
11+
env/
12+
build/
13+
develop-eggs/
14+
dist/
15+
downloads/
16+
eggs/
17+
.eggs/
18+
lib/
19+
lib64/
20+
parts/
21+
sdist/
22+
var/
23+
wheels/
24+
*.egg-info/
25+
.installed.cfg
26+
*.egg
27+
28+
# PyInstaller
29+
# Usually these files are written by a python script from a packager
30+
# before PyInstaller builds the exe, so as to inject date/other infos into it.
31+
*.manifest
32+
*.spec
33+
34+
# Installer logs
35+
pip-log.txt
36+
pip-delete-this-directory.txt
37+
38+
# Unit test / coverage reports
39+
htmlcov/
40+
.tox/
41+
.coverage
42+
.coverage.*
43+
.cache
44+
nosetests.xml
45+
coverage.xml
46+
*.cover
47+
.hypothesis/
48+
.kitchen
49+
.kitchen.local.yml
50+
kitchen.local.yml
51+
52+
# Translations
53+
*.mo
54+
*.pot
55+
56+
# Django stuff:
57+
*.log
58+
local_settings.py
59+
60+
# Flask stuff:
61+
instance/
62+
.webassets-cache
63+
64+
# Scrapy stuff:
65+
.scrapy
66+
67+
# Sphinx documentation
68+
docs/_build/
69+
70+
# PyBuilder
71+
target/
72+
73+
# Jupyter Notebook
74+
.ipynb_checkpoints
75+
76+
# pyenv
77+
.python-version
78+
79+
# celery beat schedule file
80+
celerybeat-schedule
81+
82+
# SageMath parsed files
83+
*.sage.py
84+
85+
# dotenv
86+
.env
87+
88+
# virtualenv
89+
.venv
90+
venv/
91+
ENV/
92+
93+
# Spyder project settings
94+
.spyderproject
95+
.spyproject
96+
97+
# Rope project settings
98+
.ropeproject
99+
100+
# mkdocs documentation
101+
/site
102+
103+
# mypy
104+
.mypy_cache/
105+
106+
# copied `.md` files used for conversion to `.rst` using `m2r`
107+
docs/*.md
108+
109+
# Vim
110+
*.sw[nop]

Diff for: .kitchen.yml

-26
This file was deleted.

Diff for: .travis.yml

+76
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,76 @@
1+
stages:
2+
- test
3+
- commitlint
4+
- name: release
5+
if: branch = master AND type != pull_request
6+
7+
sudo: required
8+
cache: bundler
9+
language: ruby
10+
11+
services:
12+
- docker
13+
14+
before_install:
15+
- bundle install
16+
17+
# Make sure the instances listed below match up with
18+
# the `platforms` defined in `kitchen.yml`
19+
env:
20+
matrix:
21+
- INSTANCE: default-debian-9-2019-2-py3
22+
# TODO: Re-enable this once the `systemd` service can be restarted reliably
23+
# - INSTANCE: default-ubuntu-1804-2019-2-py3
24+
- INSTANCE: default-centos-7-2019-2-py3
25+
- INSTANCE: default-fedora-29-2019-2-py3
26+
- INSTANCE: default-opensuse-leap-15-2019-2-py3
27+
- INSTANCE: default-debian-9-2018-3-py2
28+
- INSTANCE: default-ubuntu-1604-2018-3-py2
29+
- INSTANCE: default-centos-7-2018-3-py2
30+
- INSTANCE: default-fedora-29-2018-3-py2
31+
# TODO: Use this when fixed instead of `opensuse-423`
32+
# NOTE: Having to temporarily disable `opensuse-423` due to slow mirror
33+
# - INSTANCE: default-opensuse-leap-15-2018-3-py2
34+
# - INSTANCE: default-opensuse-423-2018-3-py2
35+
- INSTANCE: default-debian-8-2017-7-py2
36+
- INSTANCE: default-ubuntu-1604-2017-7-py2
37+
- INSTANCE: default-centos-6-2017-7-py2
38+
- INSTANCE: default-fedora-28-2017-7-py2
39+
- INSTANCE: default-opensuse-leap-42-2017-7-py2
40+
41+
script:
42+
- bundle exec kitchen verify ${INSTANCE}
43+
44+
jobs:
45+
include:
46+
# Define the commitlint stage
47+
- stage: commitlint
48+
language: node_js
49+
node_js: lts/*
50+
before_install: skip
51+
script:
52+
- npm install @commitlint/config-conventional -D
53+
- npm install @commitlint/travis-cli -D
54+
- commitlint-travis
55+
# Define the release stage that runs semantic-release
56+
- stage: release
57+
language: node_js
58+
node_js: lts/*
59+
before_install: skip
60+
script:
61+
# Update `AUTHORS.md`
62+
- export MAINTAINER_TOKEN=${GH_TOKEN}
63+
- go get github.com/myii/maintainer
64+
- maintainer contributor
65+
66+
# Install all dependencies required for `semantic-release`
67+
- npm install @semantic-release/changelog@3 -D
68+
- npm install @semantic-release/exec@3 -D
69+
- npm install @semantic-release/git@7 -D
70+
deploy:
71+
provider: script
72+
skip_cleanup: true
73+
script:
74+
# Run `semantic-release`
75+
- npx semantic-release@15
76+

Diff for: FORMULA

+9
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
name: postgres
2+
os: Debian, Ubuntu, Raspbian, RedHat, Fedora, CentOS, Suse, openSUSE, Gentoo, Funtoo, Arch, Manjaro, Alpine, FreeBSD, OpenBSD, Solaris, SmartOS, Windows, MacOS
3+
os_family: Debian, RedHat, Suse, Gentoo, Arch, Alpine, FreeBSD, OpenBSD, Solaris, Windows, MacOS
4+
version: 0.36.0
5+
release: 1
6+
minimum_version: 2016.11
7+
summary: Postgres formula
8+
description: Formula to install and configure PostgreSQL
9+
top_level_dir: postgres

Diff for: Gemfile

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
source "https://rubygems.org"
22

3-
gem "test-kitchen", "> 1.2.0"
4-
gem "kitchen-vagrant"
5-
gem "kitchen-salt"
3+
gem 'kitchen-docker', '>= 2.9'
4+
gem 'kitchen-salt', '>= 0.6.0'
5+
gem 'kitchen-inspec', '>= 1.1'

Diff for: commitlint.config.js

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
module.exports = {
2+
extends: ['@commitlint/config-conventional'],
3+
};

0 commit comments

Comments
 (0)