Skip to content

Commit

Permalink
ci(kitchen+gitlab): adjust matrix to add 3003
Browse files Browse the repository at this point in the history
* Automated using myii/ssf-formula#318
  • Loading branch information
myii committed Apr 23, 2021
1 parent 2d87121 commit a894f92
Show file tree
Hide file tree
Showing 3 changed files with 218 additions and 188 deletions.
110 changes: 65 additions & 45 deletions .github/workflows/kitchen.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ jobs:
# - default-ubuntu-1604-master-py3
# - default-centos-8-master-py3
# - default-centos-7-master-py3
# - default-fedora-34-master-py3
# - default-fedora-33-master-py3
# - default-fedora-32-master-py3
# - default-opensuse-leap-152-master-py3
Expand All @@ -37,62 +38,80 @@ jobs:
# - default-oraclelinux-7-master-py3
# - default-gentoo-stage3-latest-master-py3
# - default-gentoo-stage3-systemd-master-py3
# - default-debian-10-3002-5-py3
# - default-debian-9-3002-5-py3
# - default-ubuntu-2004-3002-5-py3
# - default-ubuntu-1804-3002-5-py3
# - default-ubuntu-1604-3002-5-py3
# - default-centos-8-3002-5-py3
# - default-centos-7-3002-5-py3
# - default-fedora-33-3002-5-py3
# - default-fedora-32-3002-5-py3
# - default-amazonlinux-2-3002-5-py3
# - default-oraclelinux-8-3002-5-py3
# - default-oraclelinux-7-3002-5-py3
# - default-arch-base-latest-3002-5-py3
# - default-debian-10-3003-0-py3
# - default-debian-9-3003-0-py3
# - default-ubuntu-2004-3003-0-py3
# - default-ubuntu-1804-3003-0-py3
# - default-centos-8-3003-0-py3
# - default-centos-7-3003-0-py3
# - default-fedora-34-3003-0-py3
# - default-fedora-33-3003-0-py3
# - default-fedora-32-3003-0-py3
# - default-amazonlinux-2-3003-0-py3
# - default-oraclelinux-8-3003-0-py3
# - default-oraclelinux-7-3003-0-py3
# - default-arch-base-latest-3003-0-py3
# - default-gentoo-stage3-latest-3003-0-py3
# - default-gentoo-stage3-systemd-3003-0-py3
# - default-debian-10-3002-6-py3
# - default-debian-9-3002-6-py3
# - default-ubuntu-2004-3002-6-py3
# - default-ubuntu-1804-3002-6-py3
# - default-ubuntu-1604-3002-6-py3
# - default-centos-8-3002-6-py3
# - default-centos-7-3002-6-py3
# - default-fedora-34-3002-6-py3
# - default-fedora-33-3002-6-py3
# - default-fedora-32-3002-6-py3
# - default-amazonlinux-2-3002-6-py3
# - default-oraclelinux-8-3002-6-py3
# - default-oraclelinux-7-3002-6-py3
# - default-arch-base-latest-3002-6-py3
# - default-gentoo-stage3-latest-3002-5-py3
# - default-gentoo-stage3-systemd-3002-5-py3
# - default-opensuse-leap-152-3002-2-py3
# - default-opensuse-tmbl-latest-3002-2-py3
# - default-debian-10-3001-6-py3
# - default-debian-9-3001-6-py3
# - default-ubuntu-2004-3001-6-py3
# - default-ubuntu-1804-3001-6-py3
# - default-ubuntu-1604-3001-6-py3
# - default-centos-8-3001-6-py3
# - default-centos-7-3001-6-py3
# - default-fedora-33-3001-6-py3
# - default-fedora-32-3001-6-py3
# - default-opensuse-leap-152-3001-6-py3
# - default-opensuse-tmbl-latest-3001-6-py3
# - default-amazonlinux-2-3001-6-py3
# - default-oraclelinux-8-3001-6-py3
# - default-oraclelinux-7-3001-6-py3
# - default-arch-base-latest-3001-6-py3
# - default-debian-10-3001-7-py3
# - default-debian-9-3001-7-py3
# - default-ubuntu-2004-3001-7-py3
# - default-ubuntu-1804-3001-7-py3
# - default-ubuntu-1604-3001-7-py3
# - default-centos-8-3001-7-py3
# - default-centos-7-3001-7-py3
# - default-fedora-34-3001-7-py3
# - default-fedora-33-3001-7-py3
# - default-fedora-32-3001-7-py3
# - default-opensuse-leap-152-3001-7-py3
# - default-opensuse-tmbl-latest-3001-7-py3
# - default-amazonlinux-2-3001-7-py3
# - default-oraclelinux-8-3001-7-py3
# - default-oraclelinux-7-3001-7-py3
# - default-arch-base-latest-3001-7-py3
# - default-gentoo-stage3-latest-3001-6-py3
# - default-gentoo-stage3-systemd-3001-6-py3
# - default-debian-10-3000-8-py3
# - default-debian-9-3000-8-py3
# - default-ubuntu-1804-3000-8-py3
# - default-ubuntu-1604-3000-8-py3
# - default-centos-8-3000-8-py3
# - default-centos-7-3000-8-py3
# - default-opensuse-leap-152-3000-8-py3
# - default-amazonlinux-2-3000-8-py3
# - default-oraclelinux-8-3000-8-py3
# - default-oraclelinux-7-3000-8-py3
# - default-debian-10-3000-9-py3
# - default-debian-9-3000-9-py3
# - default-ubuntu-1804-3000-9-py3
# - default-ubuntu-1604-3000-9-py3
# - default-centos-8-3000-9-py3
# - default-centos-7-3000-9-py3
# - default-opensuse-leap-152-3000-9-py3
# - default-amazonlinux-2-3000-9-py3
# - default-oraclelinux-8-3000-9-py3
# - default-oraclelinux-7-3000-9-py3
# - default-ubuntu-1804-3000-9-py2
# - default-ubuntu-1604-3000-9-py2
# - default-arch-base-latest-3000-9-py2
# - default-gentoo-stage3-latest-3000-8-py3
# - default-gentoo-stage3-systemd-3000-8-py3
# - default-ubuntu-1804-3000-8-py2
# - default-ubuntu-1604-3000-8-py2
# - default-arch-base-latest-3000-8-py2
steps:
- uses: 'actions/checkout@v2'
- uses: 'actions/cache@v1'
- name: 'Check out code'
uses: 'actions/checkout@v2'
- name: 'Set up Bundler cache'
uses: 'actions/cache@v1'
with:
path: 'vendor/bundle'
key: |
${{ runner.os }}-gems-${{ hashFiles('**/Gemfile.lock') }}
key: "${{ runner.os }}-gems-${{ hashFiles('**/Gemfile.lock') }}"
restore-keys: "${{ runner.os }}-gems-"
- name: 'Install Bundler'
run: |
Expand All @@ -101,6 +120,7 @@ jobs:
--quiet --no-document
- name: 'Run Bundler'
run: |
ruby --version
bundle config path vendor/bundle
bundle install --jobs 4 --retry 3
- name: 'Run Test Kitchen'
Expand Down
54 changes: 0 additions & 54 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,60 +26,6 @@ stages:
- *stage_lint
- *stage_release

###############################################################################
# `lint` stage: `commitlint`, `pre-commit` & `rubocop` (latest, failure allowed)
###############################################################################
commitlint:
stage: *stage_lint
image: *image_commitlint
script:
# Add `upstream` remote to get access to `upstream/master`
- 'git remote add upstream
https://gitlab.com/saltstack-formulas/icinga2-formula.git'
- 'git fetch --all'
# Set default commit hashes for `--from` and `--to`
- 'export COMMITLINT_FROM="$(git merge-base upstream/master HEAD)"'
- 'export COMMITLINT_TO="${CI_COMMIT_SHA}"'
# `coqbot` adds a merge commit to test PRs on top of the latest commit in
# the repo; amend this merge commit message to avoid failure
- |
if [ "${GITLAB_USER_LOGIN}" = "coqbot" ] \
&& [ "${CI_COMMIT_BRANCH}" != "master" ]; then
git commit --amend -m \
'chore: reword coqbot merge commit message for commitlint'
export COMMITLINT_TO=HEAD
fi
# Run `commitlint`
- 'commitlint --from "${COMMITLINT_FROM}"
--to "${COMMITLINT_TO}"
--verbose'

pre-commit:
stage: *stage_lint
image: *image_precommit
# https://pre-commit.com/#gitlab-ci-example
variables:
PRE_COMMIT_HOME: '${CI_PROJECT_DIR}/.cache/pre-commit'
cache:
key: '${CI_JOB_NAME}'
paths:
- '${PRE_COMMIT_HOME}'
script:
- 'pre-commit run --all-files --color always --verbose'

# Use a separate job for `rubocop` other than the one potentially run by `pre-commit`
# - The `pre-commit` check will only be available for formulas that pass the default
# `rubocop` check -- and must continue to do so
# - This job is allowed to fail, so can be used for all formulas
# - Furthermore, this job uses all of the latest `rubocop` features & cops,
# which will help when upgrading the `rubocop` linter used in `pre-commit`
rubocop:
allow_failure: true
stage: *stage_lint
image: *image_rubocop
script:
- 'rubocop -d -P -S --enable-pending-cops'

###############################################################################
# `release` stage: `semantic-release`
###############################################################################
Expand Down
Loading

0 comments on commit a894f92

Please sign in to comment.