-
Notifications
You must be signed in to change notification settings - Fork 14
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: Caller workflow GH_DOCS_TOKEN secret will be injected as called …
…workflow input instead of inherited secret, since secrets are not implicitly propagated to called workflow
- Loading branch information
1 parent
da07c79
commit 10740ca
Showing
1 changed file
with
5 additions
and
2 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,6 +6,9 @@ on: | |
git_tag: | ||
type: string | ||
description: The git tag (version) from the calling workflow | ||
gh_docs_token: | ||
type: string | ||
description: Assigned nvidia-ci-cd PAT with docs repo r/w pull request permissions | ||
|
||
workflow_dispatch: | ||
inputs: | ||
|
@@ -17,7 +20,7 @@ jobs: | |
docs-ci: | ||
runs-on: ubuntu-latest | ||
env: | ||
GH_TOKEN: ${{ secrets.GH_DOCS_TOKEN }} | ||
GH_TOKEN: ${{ inputs.gh_docs_token }} | ||
# keeping TAG for cases docs repo workflow is triggered with tag input | ||
TAG: ${{ inputs.git_tag }} | ||
REF_NAME: ${{ github.ref_name }} | ||
|
@@ -30,7 +33,7 @@ jobs: | |
- uses: actions/checkout@v4 | ||
with: | ||
repository: ${{ github.repository_owner }}/network-operator-docs # repo must be explicitly set here for workflow calling to behave correctly | ||
token: ${{ inputs.token || secrets.GH_DOCS_TOKEN }} | ||
token: ${{ inputs.token || inputs.gh_docs_token }} | ||
- name: Setup Go | ||
uses: actions/[email protected] | ||
with: | ||
|