onceover 3.22.0 → 4.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (65) hide show
  1. checksums.yaml +4 -4
  2. data/.github/dependabot.yml +17 -0
  3. data/.github/workflows/release.yaml +25 -17
  4. data/.github/workflows/tests.yaml +30 -4
  5. data/.gitignore +2 -1
  6. data/.rubocop.yml +4 -704
  7. data/.rubocop_todo.yml +828 -0
  8. data/CHANGELOG.md +1036 -0
  9. data/Gemfile +7 -1
  10. data/LICENSE +202 -0
  11. data/README.md +81 -35
  12. data/Rakefile +23 -14
  13. data/features/auto_vendored.feature +27 -0
  14. data/features/step_definitions/common.rb +5 -5
  15. data/features/support/cache_helper.rb +0 -1
  16. data/features/support/command_helper.rb +0 -2
  17. data/features/support/controlrepo_helper.rb +0 -2
  18. data/lib/onceover/beaker/spec_helper.rb +7 -7
  19. data/lib/onceover/beaker.rb +9 -12
  20. data/lib/onceover/cli/run.rb +1 -0
  21. data/lib/onceover/controlrepo.rb +19 -24
  22. data/lib/onceover/deploy.rb +29 -2
  23. data/lib/onceover/group.rb +1 -3
  24. data/lib/onceover/logger.rb +3 -3
  25. data/lib/onceover/node.rb +0 -2
  26. data/lib/onceover/rake_tasks.rb +9 -4
  27. data/lib/onceover/rspec/formatters.rb +3 -4
  28. data/lib/onceover/test.rb +1 -2
  29. data/lib/onceover/testconfig.rb +2 -2
  30. data/lib/onceover/vendored_modules.rb +186 -0
  31. data/onceover.gemspec +24 -21
  32. data/spec/fixtures/controlrepos/caching/spec/factsets/README.md +1 -1
  33. data/spec/fixtures/controlrepos/caching/spec/pre_conditions/README.md +1 -1
  34. data/spec/fixtures/controlrepos/factsets/spec/factsets/README.md +1 -1
  35. data/spec/fixtures/controlrepos/puppet_controlrepo/Gemfile +1 -1
  36. data/spec/fixtures/controlrepos/vendored/Puppetfile +3 -0
  37. data/spec/fixtures/controlrepos/vendored/Puppetfile.cron +5 -0
  38. data/spec/fixtures/controlrepos/vendored/environment.conf +1 -0
  39. data/spec/fixtures/controlrepos/vendored/site-modules/role/manifests/cron.pp +9 -0
  40. data/spec/fixtures/controlrepos/vendored/spec/vendored_modules/augeas_core-puppet_agent-7.30.0.json +1 -0
  41. data/spec/fixtures/controlrepos/vendored/spec/vendored_modules/augeas_core-puppet_agent-8.6.0.json +1 -0
  42. data/spec/fixtures/controlrepos/vendored/spec/vendored_modules/cron_core-puppet_agent-7.30.0.json +1 -0
  43. data/spec/fixtures/controlrepos/vendored/spec/vendored_modules/cron_core-puppet_agent-8.6.0.json +1 -0
  44. data/spec/fixtures/controlrepos/vendored/spec/vendored_modules/host_core-puppet_agent-7.30.0.json +1 -0
  45. data/spec/fixtures/controlrepos/vendored/spec/vendored_modules/host_core-puppet_agent-8.6.0.json +1 -0
  46. data/spec/fixtures/controlrepos/vendored/spec/vendored_modules/mount_core-puppet_agent-7.30.0.json +1 -0
  47. data/spec/fixtures/controlrepos/vendored/spec/vendored_modules/mount_core-puppet_agent-8.6.0.json +1 -0
  48. data/spec/fixtures/controlrepos/vendored/spec/vendored_modules/repo_tree-puppet_agent-7.30.0.json +1 -0
  49. data/spec/fixtures/controlrepos/vendored/spec/vendored_modules/repo_tree-puppet_agent-8.6.0.json +1 -0
  50. data/spec/fixtures/controlrepos/vendored/spec/vendored_modules/scheduled_task-puppet_agent-7.30.0.json +1 -0
  51. data/spec/fixtures/controlrepos/vendored/spec/vendored_modules/scheduled_task-puppet_agent-8.6.0.json +1 -0
  52. data/spec/fixtures/controlrepos/vendored/spec/vendored_modules/selinux_core-puppet_agent-7.30.0.json +1 -0
  53. data/spec/fixtures/controlrepos/vendored/spec/vendored_modules/selinux_core-puppet_agent-8.6.0.json +1 -0
  54. data/spec/fixtures/controlrepos/vendored/spec/vendored_modules/sshkeys_core-puppet_agent-7.30.0.json +1 -0
  55. data/spec/fixtures/controlrepos/vendored/spec/vendored_modules/sshkeys_core-puppet_agent-8.6.0.json +1 -0
  56. data/spec/fixtures/controlrepos/vendored/spec/vendored_modules/yumrepo_core-puppet_agent-7.30.0.json +1 -0
  57. data/spec/fixtures/controlrepos/vendored/spec/vendored_modules/yumrepo_core-puppet_agent-8.6.0.json +1 -0
  58. data/spec/fixtures/controlrepos/vendored/spec/vendored_modules/zfs_core-puppet_agent-7.30.0.json +1 -0
  59. data/spec/fixtures/controlrepos/vendored/spec/vendored_modules/zfs_core-puppet_agent-8.6.0.json +1 -0
  60. data/spec/fixtures/controlrepos/vendored/spec/vendored_modules/zone_core-puppet_agent-7.30.0.json +1 -0
  61. data/spec/fixtures/controlrepos/vendored/spec/vendored_modules/zone_core-puppet_agent-8.6.0.json +1 -0
  62. data/spec/onceover/controlrepo_spec.rb +1 -1
  63. data/templates/factsets_README.md.erb +1 -1
  64. data/templates/pre_conditions_README.md.erb +1 -1
  65. metadata +56 -9
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: f3673b1ea11e712766d85ddd0c97ff68671d698acdb0fd0f0e516182f18a3ef1
4
- data.tar.gz: 11037d12d4734ad69b94f335824154dc5056b61adb118c7a32a10ebb8f1034e7
3
+ metadata.gz: 62ace64dee90c811ed79a0d4e8388711ce808b7fef7c9ebb6f7ab1103293de73
4
+ data.tar.gz: 50c3ace5d24af8b240763e4d84699c7dd57d27d64908ddd1049914707b61aede
5
5
  SHA512:
6
- metadata.gz: 2294e1581eadcda9f2305f2c63941c7f58d00ed9e232bd19b3f40a58b1e15a7c8aa6b56750c3a480694f3e2fdc2cf74b314363cf5fca84c4a07b24607cbc6d94
7
- data.tar.gz: 250fed721814af4074477bd83d9ca77f41442c39d2476b09bd0fe15fba675a0d604077ca69d33cf861a4d318d4fe4785580b6dd8b30989ea5c7cd5e628314897
6
+ metadata.gz: 12bac2ebf77efff73c73d61a07432158e0ed6cf7ca5750fa31e55443ad5267b0dc1cc2f9bc58c0f026a72b8a8797f9b02b1783505122619e99b39888b166aea9
7
+ data.tar.gz: 45bd8b4b2f9a1c8922ff44a964fa62567c7f0a63bf1cd785b0c5d49976f14cb299b16c43dd0af44d145a452c7544d484a47b2e7dd22331645cdd015d0ab8a31d
@@ -0,0 +1,17 @@
1
+ version: 2
2
+ updates:
3
+ # raise PRs for gem updates
4
+ - package-ecosystem: bundler
5
+ directory: "/"
6
+ schedule:
7
+ interval: daily
8
+ time: "13:00"
9
+ open-pull-requests-limit: 10
10
+
11
+ # Maintain dependencies for GitHub Actions
12
+ - package-ecosystem: github-actions
13
+ directory: "/"
14
+ schedule:
15
+ interval: daily
16
+ time: "13:00"
17
+ open-pull-requests-limit: 10
@@ -1,24 +1,32 @@
1
- name: Publish Gem
1
+ name: Release
2
2
 
3
3
  on:
4
- workflow_dispatch:
4
+ push:
5
+ tags:
6
+ - '*'
7
+
5
8
  jobs:
6
- build:
9
+ release:
7
10
  runs-on: ubuntu-latest
8
- permissions:
9
- contents: write
10
-
11
+ if: github.repository_owner == 'voxpupuli'
11
12
  steps:
12
- - uses: actions/checkout@v3
13
- - uses: fregante/setup-git-user@v2
14
- - uses: ruby/setup-ruby@v1
13
+ - uses: actions/checkout@v4
14
+ - name: Install Ruby 3.3
15
+ uses: ruby/setup-ruby@v1
15
16
  with:
16
- ruby-version: 3.2.3
17
- bundler-cache: true # runs 'bundle install' and caches installed gems automatically
18
-
19
- - name: Release Gem
20
- uses: cadwallion/publish-rubygems-action@master
17
+ ruby-version: '3.3'
18
+ env:
19
+ BUNDLE_WITHOUT: release:development:rubocop
20
+ - name: Build gem
21
+ run: gem build --verbose *.gemspec
22
+ - name: Publish gem to rubygems.org
23
+ run: gem push *.gem
21
24
  env:
22
- GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
23
- RUBYGEMS_API_KEY: ${{ secrets.RUBYGEMS_API_KEY }}
24
- RELEASE_COMMAND: bundle exec rake release
25
+ GEM_HOST_API_KEY: '${{ secrets.RUBYGEMS_AUTH_TOKEN }}'
26
+ - name: Setup GitHub packages access
27
+ run: |
28
+ mkdir -p ~/.gem
29
+ echo ":github: Bearer ${{ secrets.GITHUB_TOKEN }}" >> ~/.gem/credentials
30
+ chmod 0600 ~/.gem/credentials
31
+ - name: Publish gem to GitHub packages
32
+ run: gem push --key github --host https://rubygems.pkg.github.com/voxpupuli *.gem
@@ -1,9 +1,26 @@
1
1
  name: Tests
2
+
2
3
  on:
3
- - push
4
- - pull_request
4
+ pull_request: {}
5
+ push:
6
+ branches:
7
+ - master
8
+
5
9
  jobs:
6
- full_tests:
10
+ rubocop:
11
+ env:
12
+ BUNDLE_WITHOUT: release
13
+ runs-on: ubuntu-latest
14
+ steps:
15
+ - uses: actions/checkout@v4
16
+ - name: Install Ruby ${{ matrix.ruby }}
17
+ uses: ruby/setup-ruby@v1
18
+ with:
19
+ ruby-version: "3.3"
20
+ bundler-cache: true
21
+ - name: Run Rubocop
22
+ run: bundle exec rake rubocop
23
+ test:
7
24
  strategy:
8
25
  fail-fast: false
9
26
  matrix:
@@ -22,7 +39,7 @@ jobs:
22
39
 
23
40
  runs-on: ${{ matrix.os }}
24
41
  steps:
25
- - uses: actions/checkout@v2
42
+ - uses: actions/checkout@v4
26
43
  - uses: ruby/setup-ruby@v1
27
44
  with:
28
45
  ruby-version: ${{ matrix.ruby }}
@@ -35,3 +52,12 @@ jobs:
35
52
  - env:
36
53
  PUPPET_VERSION: ${{ matrix.puppet }}
37
54
  run: bundle exec rake full_tests
55
+
56
+ tests:
57
+ needs:
58
+ - rubocop
59
+ - test
60
+ runs-on: ubuntu-latest
61
+ name: Test suite
62
+ steps:
63
+ - run: echo Test suite completed
data/.gitignore CHANGED
@@ -8,7 +8,8 @@ Gemfile.local
8
8
  /.bin
9
9
  /.ruby-version
10
10
  tmp
11
- vendor
11
+ /vendor
12
+ /.vendor
12
13
 
13
14
  # Vim
14
15
  /.projections.json