chore: extract common mocks to mocks package #3152
Workflow file for this run
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
# This workflow will regenerate code and manifests, commit&push them on a PR labeled with `renovate/auto-regenerate`. | |
# It's to make sure that Renovate-created PRs that update dependencies that might affect generated code/manifests, | |
# will have them regenerated automatically. | |
name: Regenerate on deps bump | |
on: | |
pull_request: | |
types: | |
- labeled | |
jobs: | |
regenerate: | |
timeout-minutes: ${{ fromJSON(vars.GHA_DEFAULT_TIMEOUT || 10) }} | |
if: contains(github.event.*.labels.*.name, 'renovate/auto-regenerate') | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
ref: ${{ github.event.pull_request.head.ref }} | |
token: ${{ secrets.K8S_TEAM_BOT_GH_PAT }} | |
- name: setup golang | |
uses: actions/setup-go@v5 | |
with: | |
go-version-file: go.mod | |
- uses: jdx/mise-action@v2 | |
with: | |
install: false | |
- name: regenerate | |
run: make generate manifests | |
- name: commit and push (if changes detected) | |
run: | | |
git config --global user.name "github-actions" | |
git config --global user.email "github-actions@users.noreply.github.com" | |
git add ./test/e2e/manifests ./config/crd | |
git status | |
git diff-index --quiet HEAD || \ | |
git commit -m "chore: regenerate" && \ | |
git push origin ${{ github.event.pull_request.head.ref }} |