-
-
Notifications
You must be signed in to change notification settings - Fork 240
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
GHA: Move Cron job definition to own file
This also contains https://github.com/voxpupuli/modulesync_config/pull/763/files
- Loading branch information
1 parent
dc8af30
commit 475f76b
Showing
2 changed files
with
92 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,8 +6,6 @@ name: CI | |
|
||
on: | ||
pull_request: | ||
schedule: | ||
- cron: '4 4 * * *' | ||
|
||
concurrency: | ||
group: ${{ github.head_ref }} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,92 @@ | ||
--- | ||
# Managed by modulesync - DO NOT EDIT | ||
# https://voxpupuli.org/docs/updating-files-managed-with-modulesync/ | ||
|
||
name: CI | ||
|
||
on: | ||
schedule: | ||
- cron: '4 4 * * *' | ||
|
||
concurrency: | ||
group: ${{ github.ref_name }} | ||
cancel-in-progress: true | ||
|
||
jobs: | ||
setup_matrix: | ||
name: 'Setup Test Matrix' | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 40 | ||
outputs: | ||
puppet_unit_test_matrix: ${{ steps.get-outputs.outputs.puppet_unit_test_matrix }} | ||
github_action_test_matrix: ${{ steps.get-outputs.outputs.github_action_test_matrix }} | ||
env: | ||
BUNDLE_WITHOUT: development:system_tests:release | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Setup ruby | ||
uses: ruby/setup-ruby@v1 | ||
with: | ||
ruby-version: '3.0' | ||
bundler-cache: true | ||
- name: Run static validations | ||
run: bundle exec rake validate lint check | ||
- name: Run rake rubocop | ||
run: bundle exec rake rubocop | ||
- name: Setup Test Matrix | ||
id: get-outputs | ||
run: bundle exec metadata2gha --use-fqdn --pidfile-workaround false | ||
|
||
unit: | ||
needs: setup_matrix | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 40 | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
include: ${{fromJson(needs.setup_matrix.outputs.puppet_unit_test_matrix)}} | ||
env: | ||
BUNDLE_WITHOUT: development:system_tests:release | ||
PUPPET_VERSION: "~> ${{ matrix.puppet }}.0" | ||
name: Puppet ${{ matrix.puppet }} (Ruby ${{ matrix.ruby }}) | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Setup ruby | ||
uses: ruby/setup-ruby@v1 | ||
with: | ||
ruby-version: ${{ matrix.ruby }} | ||
bundler-cache: true | ||
- name: Run tests | ||
run: bundle exec rake parallel_spec | ||
|
||
acceptance: | ||
needs: setup_matrix | ||
runs-on: ubuntu-latest | ||
env: | ||
BUNDLE_WITHOUT: development:test:release | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
include: ${{fromJson(needs.setup_matrix.outputs.github_action_test_matrix)}} | ||
name: ${{ matrix.puppet.name }} - ${{ matrix.setfile.name }} | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Setup ruby | ||
uses: ruby/setup-ruby@v1 | ||
with: | ||
ruby-version: '3.0' | ||
bundler-cache: true | ||
- name: Run tests | ||
run: bundle exec rake beaker | ||
env: | ||
BEAKER_PUPPET_COLLECTION: ${{ matrix.puppet.collection }} | ||
BEAKER_setfile: ${{ matrix.setfile.value }} | ||
|
||
tests: | ||
needs: | ||
- unit | ||
- acceptance | ||
runs-on: ubuntu-latest | ||
name: Test suite | ||
steps: | ||
- run: echo Test suite completed |