You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by pc...@apache.org on 2022/12/19 09:04:17 UTC

[camel-k] branch main updated: fix(ci): pass token via inputs

This is an automated email from the ASF dual-hosted git repository.

pcongiusti pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel-k.git


The following commit(s) were added to refs/heads/main by this push:
     new 45c22057a fix(ci): pass token via inputs
45c22057a is described below

commit 45c22057a61d1d4d44a8fb2f898471e527cb9bfb
Author: Pasquale Congiusti <pa...@gmail.com>
AuthorDate: Mon Dec 19 09:55:49 2022 +0100

    fix(ci): pass token via inputs
---
 .github/actions/automatic-updates/action.yml | 6 ++++--
 .github/workflows/automatic-updates.yml      | 3 +++
 2 files changed, 7 insertions(+), 2 deletions(-)

diff --git a/.github/actions/automatic-updates/action.yml b/.github/actions/automatic-updates/action.yml
index a1cd5e306..7757eddd9 100644
--- a/.github/actions/automatic-updates/action.yml
+++ b/.github/actions/automatic-updates/action.yml
@@ -20,6 +20,8 @@ inputs:
   branch-ref:
     required: true
     type: string
+  secretGithubToken:
+    required: true
 
 runs:
   using: "composite"
@@ -27,7 +29,7 @@ runs:
     - name: Generate changelog
       uses: ./.github/actions/changelog
       with:
-        token: ${{ secrets.GITHUB_TOKEN }}
+        token: ${{ inputs.secretGithubToken }}
         release_branch: ${{ inputs.branch-ref }}
     - name: Commit changelog
       env:
@@ -50,6 +52,6 @@ runs:
       env:
         CI_USER: "github-actions[bot]"
         CI_EMAIL: "41898282+github-actions[bot]@users.noreply.github.com"
-        CI_TOKEN: ${{ secrets.GITHUB_TOKEN }}
+        CI_TOKEN: ${{ inputs.secretGithubToken }}
       run: |
         git push "https://$CI_USER:$CI_TOKEN@github.com/$GITHUB_REPOSITORY.git" HEAD:${{ inputs.branch-ref }}
diff --git a/.github/workflows/automatic-updates.yml b/.github/workflows/automatic-updates.yml
index 1e703eadb..381dd0eec 100644
--- a/.github/workflows/automatic-updates.yml
+++ b/.github/workflows/automatic-updates.yml
@@ -38,6 +38,7 @@ jobs:
       uses: ./.github/actions/automatic-updates
       with:
         branch-ref: "main"
+        secretGithubToken: ${{ secrets.GITHUB_TOKEN }}
 
   v1_10_x:
     if: github.repository == 'apache/camel-k'
@@ -53,6 +54,7 @@ jobs:
       uses: ./.github/actions/automatic-updates
       with:
         branch-ref: "release-1.10.x"
+        secretGithubToken: ${{ secrets.GITHUB_TOKEN }}
 
   v1_11_x:
     if: github.repository == 'apache/camel-k'
@@ -68,3 +70,4 @@ jobs:
       uses: ./.github/actions/automatic-updates
       with:
         branch-ref: "release-1.11.x"
+        secretGithubToken: ${{ secrets.GITHUB_TOKEN }}