Skip to content

Commit f69bfa0

Browse files
authored
Merge pull request #895 from voxpupuli/modulesync
modulesync 4.2.0
2 parents 3ebfda0 + bff33ff commit f69bfa0

File tree

19 files changed

+98
-80
lines changed

19 files changed

+98
-80
lines changed

.editorconfig

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
# editorconfig.org
22

3-
# MANAGED BY MODULESYNC
3+
# Managed by modulesync - DO NOT EDIT
4+
# https://voxpupuli.org/docs/updating-files-managed-with-modulesync/
45

56
root = true
67

.github/CONTRIBUTING.md

Lines changed: 3 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ By participating in this project you agree to abide by its terms.
2525

2626
* Fork the repo.
2727
* Create a separate branch for your change.
28-
* We only take pull requests with passing tests, and documentation. [travis-ci](http://travis-ci.org) runs the tests for us. You can also execute them locally. This is explained [in a later section](#the-test-matrix).
28+
* We only take pull requests with passing tests, and documentation. [GitHub Actions](https://docs.github.com/en/actions) run the tests for us. You can also execute them locally. This is explained [in a later section](#the-test-matrix).
2929
* Checkout [our docs](https://voxpupuli.org/docs/reviewing_pr/) we use to review a module and the [official styleguide](https://puppet.com/docs/puppet/6.0/style_guide.html). They provide some guidance for new code that might help you before you submit a pull request.
3030
* Add a test for your change. Only refactoring and documentation changes require no new tests. If you are adding functionality or fixing a bug, please add a test.
3131
* Squash your commits down into logical components. Make sure to rebase against our current master.
@@ -232,33 +232,7 @@ simple tests against it after applying the module. You can run this
232232
with:
233233

234234
```sh
235-
bundle exec rake beaker
236-
```
237-
238-
This will run the tests on the module's default nodeset. You can override the
239-
nodeset used, e.g.,
240-
241-
```sh
242-
BEAKER_set=centos-7-x64 bundle exec rake beaker
243-
```
244-
245-
There are default rake tasks for the various acceptance test modules, e.g.,
246-
247-
```sh
248-
bundle exec rake beaker:centos-7-x64
249-
bundle exec rake beaker:ssh:centos-7-x64
250-
```
251-
252-
If you don't want to have to recreate the virtual machine every time you can
253-
use `BEAKER_destroy=no` and `BEAKER_provision=no`. On the first run you will at
254-
least need `BEAKER_provision` set to yes (the default). The Vagrantfile for the
255-
created virtual machines will be in `.vagrant/beaker_vagrant_files`.
256-
257-
Beaker also supports docker containers. We also use that in our automated CI
258-
pipeline at [travis-ci](http://travis-ci.org). To use that instead of Vagrant:
259-
260-
```sh
261-
PUPPET_INSTALL_TYPE=agent BEAKER_IS_PE=no BEAKER_PUPPET_COLLECTION=puppet6 BEAKER_debug=true BEAKER_setfile=debian10-64{hypervisor=docker} BEAKER_destroy=yes bundle exec rake beaker
235+
BEAKER_setfile=debian10-x64 bundle exec rake beaker
262236
```
263237

264238
You can replace the string `debian10` with any common operating system.
@@ -272,11 +246,7 @@ The following strings are known to work:
272246
* centos7
273247
* centos8
274248

275-
The easiest way to debug in a docker container is to open a shell:
276-
277-
```sh
278-
docker exec -it -u root ${container_id_or_name} bash
279-
```
249+
For more information and tips & tricks, see [voxpupuli-acceptance's documentation](https://github.com/voxpupuli/voxpupuli-acceptance#running-tests).
280250

281251
The source of this file is in our [modulesync_config](https://github.com/voxpupuli/modulesync_config/blob/master/moduleroot/.github/CONTRIBUTING.md.erb)
282252
repository.

.github/workflows/ci.yml

Lines changed: 29 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,33 +1,44 @@
1+
---
2+
# Managed by modulesync - DO NOT EDIT
3+
# https://voxpupuli.org/docs/updating-files-managed-with-modulesync/
4+
15
name: CI
26

37
on: pull_request
48

9+
concurrency:
10+
group: ${{ github.head_ref }}
11+
cancel-in-progress: true
12+
513
jobs:
614
setup_matrix:
715
name: 'Setup Test Matrix'
816
runs-on: ubuntu-latest
17+
timeout-minutes: 40
918
outputs:
10-
beaker_setfiles: ${{ steps.get-outputs.outputs.beaker_setfiles }}
11-
puppet_major_versions: ${{ steps.get-outputs.outputs.puppet_major_versions }}
1219
puppet_unit_test_matrix: ${{ steps.get-outputs.outputs.puppet_unit_test_matrix }}
20+
github_action_test_matrix: ${{ steps.get-outputs.outputs.github_action_test_matrix }}
1321
env:
14-
BUNDLE_WITHOUT: development:test:release
22+
BUNDLE_WITHOUT: development:system_tests:release
1523
steps:
1624
- uses: actions/checkout@v2
1725
- name: Setup ruby
1826
uses: ruby/setup-ruby@v1
1927
with:
20-
ruby-version: '2.7'
28+
ruby-version: '3.0'
2129
bundler-cache: true
22-
- name: Run rake validate
23-
run: bundle exec rake validate
30+
- name: Run static validations
31+
run: bundle exec rake validate lint check
32+
- name: Run rake rubocop
33+
run: bundle exec rake rubocop
2434
- name: Setup Test Matrix
2535
id: get-outputs
2636
run: bundle exec metadata2gha --use-fqdn --pidfile-workaround false
2737

2838
unit:
2939
needs: setup_matrix
3040
runs-on: ubuntu-latest
41+
timeout-minutes: 40
3142
strategy:
3243
fail-fast: false
3344
matrix:
@@ -44,7 +55,7 @@ jobs:
4455
ruby-version: ${{ matrix.ruby }}
4556
bundler-cache: true
4657
- name: Run tests
47-
run: bundle exec rake
58+
run: bundle exec rake parallel_spec
4859

4960
acceptance:
5061
needs: setup_matrix
@@ -54,22 +65,26 @@ jobs:
5465
strategy:
5566
fail-fast: false
5667
matrix:
57-
setfile: ${{fromJson(needs.setup_matrix.outputs.beaker_setfiles)}}
58-
puppet: ${{fromJson(needs.setup_matrix.outputs.puppet_major_versions)}}
68+
include: ${{fromJson(needs.setup_matrix.outputs.github_action_test_matrix)}}
5969
name: ${{ matrix.puppet.name }} - ${{ matrix.setfile.name }}
6070
steps:
61-
- name: Enable IPv6 on docker
62-
run: |
63-
echo '{"ipv6":true,"fixed-cidr-v6":"2001:db8:1::/64"}' | sudo tee /etc/docker/daemon.json
64-
sudo service docker restart
6571
- uses: actions/checkout@v2
6672
- name: Setup ruby
6773
uses: ruby/setup-ruby@v1
6874
with:
69-
ruby-version: '2.7'
75+
ruby-version: '3.0'
7076
bundler-cache: true
7177
- name: Run tests
7278
run: bundle exec rake beaker
7379
env:
7480
BEAKER_PUPPET_COLLECTION: ${{ matrix.puppet.collection }}
7581
BEAKER_setfile: ${{ matrix.setfile.value }}
82+
83+
tests:
84+
needs:
85+
- unit
86+
- acceptance
87+
runs-on: ubuntu-latest
88+
name: Test suite
89+
steps:
90+
- run: echo Test suite completed

.github/workflows/release.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
---
2+
# Managed by modulesync - DO NOT EDIT
3+
# https://voxpupuli.org/docs/updating-files-managed-with-modulesync/
4+
15
name: Release
26

37
on:
@@ -12,6 +16,7 @@ jobs:
1216
deploy:
1317
name: 'deploy to forge'
1418
runs-on: ubuntu-latest
19+
if: github.repository_owner == 'voxpupuli'
1520
steps:
1621
- name: Checkout repository
1722
uses: actions/checkout@v2

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
# Managed by modulesync - DO NOT EDIT
2+
# https://voxpupuli.org/docs/updating-files-managed-with-modulesync/
3+
14
pkg/
25
Gemfile.lock
36
Gemfile.local

.msync.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,5 @@
11
---
2-
modulesync_config_version: '4.0.0'
2+
# Managed by modulesync - DO NOT EDIT
3+
# https://voxpupuli.org/docs/updating-files-managed-with-modulesync/
4+
5+
modulesync_config_version: '4.2.0'

.overcommit.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
# Managed by https://github.com/voxpupuli/modulesync_configs
1+
# Managed by modulesync - DO NOT EDIT
2+
# https://voxpupuli.org/docs/updating-files-managed-with-modulesync/
23
#
34
# Hooks are only enabled if you take action.
45
#

.pmtignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
# Managed by modulesync - DO NOT EDIT
2+
# https://voxpupuli.org/docs/updating-files-managed-with-modulesync/
3+
14
docs/
25
pkg/
36
Gemfile

.rspec

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,5 @@
1+
# Managed by modulesync - DO NOT EDIT
2+
# https://voxpupuli.org/docs/updating-files-managed-with-modulesync/
3+
14
--format documentation
25
--color

.rspec_parallel

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,4 @@
1+
# Managed by modulesync - DO NOT EDIT
2+
# https://voxpupuli.org/docs/updating-files-managed-with-modulesync/
3+
14
--format progress

0 commit comments

Comments
 (0)