Skip to content

Commit d252612

Browse files
avivkellerRafaelGSS
authored andcommitted
meta: store actions secrets in environment
PR-URL: #53930 Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
1 parent 0f1fe63 commit d252612

File tree

2 files changed

+14
-6
lines changed

2 files changed

+14
-6
lines changed

.github/workflows/auto-start-ci.yml

+7-3
Original file line numberDiff line numberDiff line change
@@ -59,11 +59,15 @@ jobs:
5959

6060
- name: Setup @node-core/utils
6161
run: |
62-
ncu-config set username ${{ secrets.JENKINS_USER }}
63-
ncu-config set token "${{ secrets.GH_USER_TOKEN }}"
64-
ncu-config set jenkins_token ${{ secrets.JENKINS_TOKEN }}
62+
ncu-config set username "$USERNAME"
63+
ncu-config set token "$GH_TOKEN"
64+
ncu-config set jenkins_token "$JENKINS_TOKEN"
6565
ncu-config set owner "${{ github.repository_owner }}"
6666
ncu-config set repo "$(echo ${{ github.repository }} | cut -d/ -f2)"
67+
env:
68+
USERNAME: ${{ secrets.JENKINS_USER }}
69+
GH_TOKEN: ${{ secrets.GH_USER_TOKEN }}
70+
JENKINS_TOKEN: ${{ secrets.JENKINS_TOKEN }}
6771

6872
- name: Start the CI
6973
run: ./tools/actions/start-ci.sh ${{ needs.get-prs-for-ci.outputs.numbers }}

.github/workflows/commit-queue.yml

+7-3
Original file line numberDiff line numberDiff line change
@@ -86,11 +86,15 @@ jobs:
8686
run: |
8787
ncu-config set branch ${GITHUB_REF_NAME}
8888
ncu-config set upstream origin
89-
ncu-config set username "${{ secrets.GH_USER_NAME }}"
90-
ncu-config set token "${{ secrets.GH_USER_TOKEN }}"
91-
ncu-config set jenkins_token "${{ secrets.JENKINS_TOKEN }}"
89+
ncu-config set username "$USERNAME"
90+
ncu-config set token "$GH_TOKEN"
91+
ncu-config set jenkins_token "$JENKINS_TOKEN"
9292
ncu-config set repo "${REPOSITORY}"
9393
ncu-config set owner "${OWNER}"
94+
env:
95+
USERNAME: ${{ secrets.JENKINS_USER }}
96+
GH_TOKEN: ${{ secrets.GH_USER_TOKEN }}
97+
JENKINS_TOKEN: ${{ secrets.JENKINS_TOKEN }}
9498

9599
- name: Start the Commit Queue
96100
run: ./tools/actions/commit-queue.sh ${{ env.OWNER }} ${{ env.REPOSITORY }} ${{ needs.get_mergeable_prs.outputs.numbers }}

0 commit comments

Comments
 (0)