Skip to content

Commit cc648af

Browse files
committed
[puppetsync] Clean up for linters
Clean up files distributed by puppetsync for various linters. Also fix a quoting issue in create-github-release action.
1 parent 3bdfb52 commit cc648af

6 files changed

+85
-59
lines changed

.github/workflows/add_new_issue_to_triage_project.yml

+20-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,26 @@
1+
# Add new issues to triage project board (https://github.com/orgs/simp/projects/11)
2+
# ------------------------------------------------------------------------------
3+
#
4+
# NOTICE: **This file is maintained with puppetsync**
5+
#
6+
# This file is updated automatically as part of a puppet module baseline.
7+
#
8+
# The next baseline sync will overwrite any local changes to this file!
9+
#
10+
# ==============================================================================
11+
# This pipeline uses the following GitHub Action Secrets:
12+
#
13+
# GitHub Secret variable Notes
14+
# ------------------------------- ---------------------------------------
15+
# AUTO_TRIAGE_TOKEN Token with appropriate permissions
16+
#
17+
# ------------------------------------------------------------------------------
18+
#
19+
#
120
---
221
name: Add new issues to triage project
322

4-
on:
23+
'on':
524
issues:
625
types:
726
- opened

.github/workflows/pr_tests.yml

+12-12
Original file line numberDiff line numberDiff line change
@@ -11,23 +11,23 @@
1111
# The testing matrix considers ruby/puppet versions supported by SIMP and PE:
1212
# ------------------------------------------------------------------------------
1313
# Release Puppet Ruby EOL
14-
# PE 2019.8 6.22 2.5 2022-12 (LTS)
15-
# PE 2021.Y 7.x 2.7 Quarterly updates
14+
# PE 2021.Y 7.x 2.7 2025-02 (LTS)
15+
# PE 2023.Y 8.x 3.2 Biannual updates
1616
#
1717
# https://puppet.com/docs/pe/latest/component_versions_in_recent_pe_releases.html
1818
# https://puppet.com/misc/puppet-enterprise-lifecycle
1919
# ==============================================================================
2020
#
2121
# https://docs.github.com/en/actions/reference/events-that-trigger-workflows
2222
#
23-
23+
---
2424
name: PR Tests
25-
on:
25+
'on':
2626
pull_request:
2727
types: [opened, reopened, synchronize]
2828

2929
env:
30-
PUPPET_VERSION: '~> 7'
30+
PUPPET_VERSION: '~> 8'
3131

3232
jobs:
3333
puppet-syntax:
@@ -38,7 +38,7 @@ jobs:
3838
- name: "Install Ruby ${{matrix.puppet.ruby_version}}"
3939
uses: ruby/setup-ruby@v1 # ruby/setup-ruby@ec106b438a1ff6ff109590de34ddc62c540232e0
4040
with:
41-
ruby-version: 2.7
41+
ruby-version: 3.2
4242
bundler-cache: true
4343
- run: "bundle exec rake syntax"
4444

@@ -50,13 +50,13 @@ jobs:
5050
- name: "Install Ruby ${{matrix.puppet.ruby_version}}"
5151
uses: ruby/setup-ruby@v1
5252
with:
53-
ruby-version: 2.7
53+
ruby-version: 3.2
5454
bundler-cache: true
5555
- run: "bundle exec rake lint"
5656
- run: "bundle exec rake metadata_lint"
5757

5858
ruby-style:
59-
if: false # TODO Modules will need: rubocop in Gemfile, .rubocop.yml
59+
if: false # TODO Modules will need: rubocop in Gemfile, .rubocop.yml
6060
name: 'Ruby Style (experimental)'
6161
runs-on: ubuntu-latest
6262
continue-on-error: true
@@ -65,7 +65,7 @@ jobs:
6565
- name: "Install Ruby ${{matrix.puppet.ruby_version}}"
6666
uses: ruby/setup-ruby@v1
6767
with:
68-
ruby-version: 2.7
68+
ruby-version: 3.2
6969
bundler-cache: true
7070
- run: |
7171
bundle show
@@ -76,10 +76,10 @@ jobs:
7676
runs-on: ubuntu-latest
7777
steps:
7878
- uses: actions/checkout@v3
79-
- name: 'Install Ruby 2.7'
79+
- name: 'Install Ruby 3.2'
8080
uses: ruby/setup-ruby@v1
8181
with:
82-
ruby-version: 2.7
82+
ruby-version: 3.2
8383
bundler-cache: true
8484
- run: bundle exec rake check:dot_underscore
8585
- run: bundle exec rake check:test_file
@@ -92,7 +92,7 @@ jobs:
9292
- name: 'Install Ruby ${{matrix.puppet.ruby_version}}'
9393
uses: ruby/setup-ruby@v1
9494
with:
95-
ruby-version: 2.7
95+
ruby-version: 3.2
9696
bundler-cache: true
9797
- name: 'Tags and changelogs'
9898
run: |

.github/workflows/release_rpms.yml

+8-8
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@
3131
---
3232
name: 'RELENG: Build + attach RPMs to GitHub Release'
3333

34-
on:
34+
'on':
3535
workflow_dispatch:
3636
inputs:
3737
release_tag:
@@ -71,10 +71,10 @@ on:
7171
description: "Dry run (Test-build RPMs)"
7272
required: false
7373
default: 'no'
74-
#verbose:
75-
# description: 'Verbose RPM builds when "yes"'
76-
# required: false
77-
# default: 'no'
74+
# verbose:
75+
# description: 'Verbose RPM builds when "yes"'
76+
# required: false
77+
# default: 'no'
7878
rebuild_number:
7979
description: 'If this is an RPM rebuild, put the number of the rebuild here'
8080
required: false
@@ -255,13 +255,13 @@ jobs:
255255
simp_core_ref_for_building_rpms: ${{ secrets.SIMP_CORE_REF_FOR_BUILDING_RPMS }}
256256
simp_builder_docker_image: 'docker.io/simpproject/simp_build_${{ github.event.inputs.build_container_os }}:latest'
257257
path_to_build: "${{ (github.event.inputs.path_to_build != null && format('{0}/{1}', github.workspace, github.event.inputs.path_to_build)) || github.workspace }}"
258-
verbose: 'no' #${{ github.event.inputs.verbose }}
258+
verbose: 'no' # ${{ github.event.inputs.verbose }}
259259
260260
- name: "Wipe all previous assets from GitHub Release (when clean == 'yes')"
261261
if: ${{ github.event.inputs.clean == 'yes' && github.event.inputs.dry_run != 'yes' }}
262262
uses: actions/github-script@v6
263263
env:
264-
release_id: ${{ steps.release-api.outputs.id }}
264+
release_id: ${{ steps.release-api.outputs.id }}
265265
with:
266266
github-token: ${{ github.event.inputs.target_repo_token || secrets.GITHUB_TOKEN }}
267267
script: |
@@ -282,7 +282,7 @@ jobs:
282282
env:
283283
rpm_file_paths: ${{ steps.build-and-sign-rpm.outputs.rpm_file_paths }}
284284
rpm_gpg_file: ${{ steps.build-and-sign-rpm.outputs.rpm_gpg_file }}
285-
release_id: ${{ steps.release-api.outputs.id }}
285+
release_id: ${{ steps.release-api.outputs.id }}
286286
clobber: ${{ github.event.inputs.clobber }}
287287
clean: ${{ github.event.inputs.clean }}
288288
dry_run: ${{ github.event.inputs.dry_run }}

.github/workflows/tag_deploy.yml

+12-9
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030
---
3131
name: 'Tag: Release to GitHub w/RPMs + Puppet Forge'
3232

33-
on:
33+
'on':
3434
push:
3535
tags:
3636
# NOTE: These filter patterns aren't actually regexes:
@@ -39,7 +39,7 @@ on:
3939
- '[0-9]+\.[0-9]+\.[0-9]+\-[a-z]+[0-9]+'
4040

4141
env:
42-
PUPPET_VERSION: '~> 7'
42+
PUPPET_VERSION: '~> 8'
4343

4444
jobs:
4545
releng-checks:
@@ -55,7 +55,7 @@ jobs:
5555
clean: true
5656
- uses: ruby/setup-ruby@v1
5757
with:
58-
ruby-version: 2.7
58+
ruby-version: 3.2
5959
bundler-cache: true
6060
- run: bundle exec rake pkg:check_version
6161
- run: bundle exec rake pkg:compare_latest_tag
@@ -67,7 +67,8 @@ jobs:
6767

6868
create-github-release:
6969
name: Deploy GitHub Release
70-
needs: [ releng-checks ]
70+
needs:
71+
- releng-checks
7172
if: github.repository_owner == 'simp'
7273
runs-on: ubuntu-latest
7374
outputs:
@@ -117,17 +118,18 @@ jobs:
117118
id: create_release
118119
env:
119120
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
120-
IS_PRERELASE: ${{ steps.tag-check.outputs.prerelease }}
121+
IS_PRERELEASE: ${{ steps.tag-check.outputs.prerelease }}
121122
run: |
122123
echo "${RELEASE_MESSAGE}" > /tmp/.commit-msg.txt
123124
args=(-F /tmp/.commit-msg.txt)
124-
[[ $IS_PRERELASE == yes ]] && args+=(--prerelease)
125+
[[ "$IS_PRERELEASE" == yes ]] && args+=(--prerelease)
125126
126127
gh release create ${args[@]} "$TARGET_TAG"
127128
128129
build-and-attach-rpms:
129130
name: Trigger RPM release
130-
needs: [ create-github-release ]
131+
needs:
132+
- create-github-release
131133
if: github.repository_owner == 'simp'
132134
runs-on: ubuntu-latest
133135
env:
@@ -165,7 +167,8 @@ jobs:
165167
166168
deploy-to-puppet-forge:
167169
name: 'Deploy PuppetForge Release'
168-
needs: [ create-github-release ]
170+
needs:
171+
- create-github-release
169172
if: (github.repository_owner == 'simp') && (needs.create-github-release.outputs.prerelease != 'yes')
170173
runs-on: ubuntu-latest
171174
env:
@@ -180,7 +183,7 @@ jobs:
180183
clean: true
181184
- uses: ruby/setup-ruby@v1
182185
with:
183-
ruby-version: 2.7
186+
ruby-version: 3.2
184187
bundler-cache: true
185188
- name: Build Puppet module (PDK)
186189
run: bundle exec pdk build --force

.github/workflows/validate_tokens.yml

+1-2
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
---
2222
name: 'Manual: Validate API tokens'
2323

24-
on:
24+
'on':
2525
- workflow_dispatch
2626

2727
jobs:
@@ -66,4 +66,3 @@ jobs:
6666
echo "::debug ::${scopes}"
6767
exit 1
6868
fi
69-

0 commit comments

Comments
 (0)