Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix new generate-docs-helm-tests-renovate-pr #10793

Merged
Merged
38 changes: 22 additions & 16 deletions .github/workflows/generate-docs-helm-tests-renovate-pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,19 @@ jobs:
- name: Get build image from Makefile
id: build_image_step
run: echo "build_image=$(make print-build-image)" >> "$GITHUB_OUTPUT"
outputs:
build_image: ${{ steps.build_image_step.outputs.build_image }}

lint_and_update:
runs-on: ubuntu-latest
needs:
- prepare
container:
image: ${{ needs.prepare.outputs.build_image }}
steps:
- name: Checkout Repository
uses: actions/checkout@v4

# Retrieve GitHub App Credentials from Vault
- name: Retrieve GitHub App Credentials from Vault
id: get-secrets
Expand All @@ -34,28 +47,21 @@ jobs:
repo_secrets: |
APP_ID=mimir-github-bot:app_id
PRIVATE_KEY=mimir-github-bot:private_key
# Generate GitHub App Token

# Generate GitHub App Token (Directly in the Job That Needs It)
- name: Generate GitHub App Token
id: app-token
id: token
uses: actions/create-github-app-token@v1
with:
app-id: ${{ steps.get-secrets.outputs.APP_ID }}
private-key: ${{ steps.get-secrets.outputs.PRIVATE_KEY }}
# Variables generated by the previous step get-secrets
app-id: ${{ env.APP_ID }}
private-key: ${{ env.PRIVATE_KEY }}
owner: ${{ github.repository_owner }}
outputs:
build_image: ${{ steps.build_image_step.outputs.build_image }}

lint_and_update:
runs-on: ubuntu-latest
needs:
- prepare
container:
image: ${{ needs.prepare.outputs.build_image }}
steps:
- name: Checkout Repository
- name: Checkout Repository with App Token
uses: actions/checkout@v4
with:
token: ${{ steps.app-token.outputs.token }}
token: ${{ steps.token.outputs.token }}

- name: Run Git Config
run: |
Expand All @@ -69,7 +75,7 @@ jobs:
- name: Checkout Pull Request Branch
run: gh pr checkout ${{ github.event.pull_request.number }}
env:
GITHUB_TOKEN: ${{ steps.app-token.outputs.token }}
GITHUB_TOKEN: ${{ steps.token.outputs.token }}

- name: Run make targets
id: update
Expand Down
Loading