Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
31db4c8
feat: enable Octo STS for downstream automation
erikgb Aug 30, 2025
2b54d29
Merge pull request #362 from erikgb/enable-octo-sts
cert-manager-prow[bot] Aug 30, 2025
b976d40
Add ok-to-test label to downstream Renovate PRs
erikgb Aug 30, 2025
00feb56
Merge pull request #364 from cert-manager-bot/cherry-pick-363-to-octo…
cert-manager-prow[bot] Aug 30, 2025
1db59af
Use token obtained from Octo STS for Git operations
erikgb Aug 30, 2025
82d01bc
Merge pull request #365 from erikgb/fix-git-token
cert-manager-prow[bot] Aug 30, 2025
2093e7d
Add vendor-go target to Renovate postUpgradeTasks
erikgb Aug 30, 2025
c6d42ca
Merge pull request #366 from erikgb/vendor-go-2
cert-manager-prow[bot] Aug 30, 2025
1fd4102
Simplify use of Octo STS token in self-upgrade workflow
erikgb Aug 30, 2025
ab697d6
Merge pull request #367 from erikgb/simplify-self-upgrade
cert-manager-prow[bot] Aug 30, 2025
f61bbc8
Grant make-self-upgrade write access to workflows
erikgb Aug 31, 2025
c935f5d
Remove Renovate push trigger
erikgb Aug 31, 2025
8df7c3f
Anchor Octo STS subject patterns
erikgb Aug 31, 2025
c479576
Align make-self-upgrade and renovate workflows
erikgb Aug 31, 2025
d463e57
Merge pull request #371 from erikgb/align-workflows
cert-manager-prow[bot] Aug 31, 2025
bb846fe
Merge pull request #370 from erikgb/anchor-subject-patterns
cert-manager-prow[bot] Aug 31, 2025
af84764
Merge pull request #368 from erikgb/self-upgrade-workflows
cert-manager-prow[bot] Aug 31, 2025
8639fd2
Merge pull request #369 from erikgb/no-push-trigger
cert-manager-prow[bot] Aug 31, 2025
db123f4
Add concurrency control to Renovate workflow
erikgb Aug 31, 2025
a3254b9
chore(deps): update misc github actions
octo-sts[bot] Aug 31, 2025
792535d
Merge pull request #378 from cert-manager/renovate/octo-sts-poc-misc-…
cert-manager-prow[bot] Aug 31, 2025
0378b84
Use Octo STS token to create self-upgrade PR
erikgb Aug 31, 2025
fe1770d
Merge pull request #380 from erikgb/github-script-token
cert-manager-prow[bot] Aug 31, 2025
6a186a7
Merge pull request #374 from erikgb/concurrency-control
cert-manager-prow[bot] Aug 31, 2025
c6eaf4b
Add ok-to-test label to self-upgrade PRs
erikgb Aug 31, 2025
ffacb1a
Merge pull request #382 from cert-manager-bot/cherry-pick-381-to-octo…
cert-manager-prow[bot] Aug 31, 2025
91a88b9
Set cert-manager-bot as Git author of Renovate PRs
erikgb Aug 31, 2025
3768789
Merge pull request #384 from cert-manager-bot/cherry-pick-383-to-octo…
cert-manager-prow[bot] Aug 31, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/renovate.json5
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
{
$schema: 'https://docs.renovatebot.com/renovate-schema.json',
enabled: true,
gitAuthor: 'cert-manager-bot <cert-manager-bot@users.noreply.github.com>',
enabledManagers: [
'custom.regex',
'gomod',
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/base-images-upgrade.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ jobs:
run: |
make print-go-version >> "$GITHUB_OUTPUT"

- uses: actions/setup-go@0a12ed9d6a96ab950c8f026ed9f722fe0da7ef32 # v5.0.2
- uses: actions/setup-go@d35c59abb061a4a6fb18e82ac0862c26744d6ab5 # v5.5.0
with:
go-version: ${{ steps.go-version.outputs.result }}

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/e2e-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:
run: |
make print-go-version >> "$GITHUB_OUTPUT"

- uses: actions/setup-go@v5
- uses: actions/setup-go@d35c59abb061a4a6fb18e82ac0862c26744d6ab5 # v5
with:
go-version: ${{ steps.go-version.outputs.result }}

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/kind-images-upgrade.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ jobs:
run: |
make print-go-version >> "$GITHUB_OUTPUT"

- uses: actions/setup-go@0a12ed9d6a96ab950c8f026ed9f722fe0da7ef32 # v5.0.2
- uses: actions/setup-go@d35c59abb061a4a6fb18e82ac0862c26744d6ab5 # v5.5.0
with:
go-version: ${{ steps.go-version.outputs.result }}

Expand Down
22 changes: 0 additions & 22 deletions modules/repository-base/base-dependabot/.github/dependabot.yaml

This file was deleted.

19 changes: 18 additions & 1 deletion modules/repository-base/base-dependabot/.github/renovate.json5
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@
{
$schema: 'https://docs.renovatebot.com/renovate-schema.json',
enabled: true,
gitAuthor: 'cert-manager-bot <cert-manager-bot@users.noreply.github.com>',
enabledManagers: [
'github-actions',
'gomod',
],
extends: [
Expand All @@ -19,15 +21,25 @@
labels: [
'dependencies',
'kind/cleanup',
'ok-to-test',
'release-note-none',
],
postUpgradeTasks: {
commands: [
'make generate',
'make vendor-go generate',
],
executionMode: 'branch',
},
packageRules: [
{
groupName: 'Misc GitHub actions',
matchManagers: [
'github-actions',
],
matchPackageNames: [
'*',
],
},
{
groupName: 'Misc Go deps',
matchManagers: [
Expand Down Expand Up @@ -88,5 +100,10 @@
],
ignorePaths: [
'**/vendor/**',

// Exclude files that are mastered from makefile-modules and shouldn't be upgraded in projects using makefile-modules.
'.github/workflows/govulncheck.yaml',
'.github/workflows/make-self-upgrade.yaml',
'.github/workflows/renovate.yaml',
],
}
Original file line number Diff line number Diff line change
Expand Up @@ -5,22 +5,25 @@ name: Renovate
on:
workflow_dispatch: {}
schedule:
- cron: '0 2 * * *'
- cron: '0/30 * * * *'

permissions:
contents: read

jobs:
renovate:
runs-on: ubuntu-latest
# This concurrency control is added to allow a quite aggressive cron schedule (see above),
# while at the same time avoid multiple Renovate runs at the same time.
# In some of our projects, e.g. cert-manager, the Renovate run can take some time.
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: false # Must allow the longest running job to finish.

if: github.repository == '{{REPLACE:GH-REPOSITORY}}'

permissions:
contents: write
issues: write
statuses: write
pull-requests: write
id-token: write

steps:
- name: Fail if branch is not head of branch.
Expand All @@ -29,11 +32,20 @@ jobs:
echo "This workflow should not be run on a non-branch-head."
exit 1

- name: Octo STS Token Exchange
uses: octo-sts/action@e480437973a6f6ac2e9caa40ecabedc870d76395 # main
id: octo-sts
with:
scope: '{{REPLACE:GH-REPOSITORY}}'
identity: renovate

- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
# Adding `fetch-depth: 0` makes sure tags are also fetched. We need
# the tags so `git describe` returns a valid version.
# see https://github.com/actions/checkout/issues/701 for extra info about this option
with: { fetch-depth: 0 }
with:
fetch-depth: 0
token: ${{ steps.octo-sts.outputs.token }}

- id: go-version
run: |
Expand All @@ -47,7 +59,7 @@ jobs:
uses: renovatebot/github-action@a447f09147d00e00ae2a82ad5ef51ca89352da80 # v43.0.9
with:
configurationFile: .github/renovate.json5
token: ${{ secrets.GITHUB_TOKEN }}
token: ${{ steps.octo-sts.outputs.token }}
env:
RENOVATE_REPOSITORIES: '["${{ github.repository }}"]'
RENOVATE_ONBOARDING: "false"
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
issuer: https://token.actions.githubusercontent.com
subject_pattern: ^repo:{{REPLACE:GH-REPOSITORY}}:ref:refs/heads/(main|master)$

permissions:
contents: write
pull_requests: write
workflows: write
11 changes: 11 additions & 0 deletions modules/repository-base/base/.github/chainguard/renovate.sts.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
issuer: https://token.actions.githubusercontent.com
subject_pattern: ^repo:{{REPLACE:GH-REPOSITORY}}:ref:refs/heads/(main|master)$

permissions:
administration: read
contents: write
issues: write
pull_requests: write
security_events: read
statuses: write
workflows: write
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,7 @@ jobs:
if: github.repository == '{{REPLACE:GH-REPOSITORY}}'

permissions:
contents: write
pull-requests: write
id-token: write

env:
SOURCE_BRANCH: "${{ github.ref_name }}"
Expand All @@ -32,11 +31,20 @@ jobs:
echo "This workflow should not be run on a non-branch-head."
exit 1

- name: Octo STS Token Exchange
uses: octo-sts/action@e480437973a6f6ac2e9caa40ecabedc870d76395 # main
id: octo-sts
with:
scope: '{{REPLACE:GH-REPOSITORY}}'
identity: make-self-upgrade

- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
# Adding `fetch-depth: 0` makes sure tags are also fetched. We need
# the tags so `git describe` returns a valid version.
# see https://github.com/actions/checkout/issues/701 for extra info about this option
with: { fetch-depth: 0 }
with:
fetch-depth: 0
token: ${{ steps.octo-sts.outputs.token }}

- id: go-version
run: |
Expand Down Expand Up @@ -75,6 +83,7 @@ jobs:
- if: ${{ steps.is-up-to-date.outputs.result != 'true' }}
uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7.0.1
with:
github-token: ${{ steps.octo-sts.outputs.token }}
script: |
const { repo, owner } = context.repo;
const pulls = await github.rest.pulls.list({
Expand All @@ -100,6 +109,6 @@ jobs:
owner,
repo,
issue_number: result.data.number,
labels: ['skip-review']
labels: ['ok-to-test', 'skip-review']
});
}
Loading