Skip to content

Commit

Permalink
test dynamic token input
Browse files Browse the repository at this point in the history
  • Loading branch information
K4ST0R committed Apr 29, 2024
1 parent 77aa689 commit 5579804
Showing 1 changed file with 19 additions and 3 deletions.
22 changes: 19 additions & 3 deletions .github/workflows/manual-deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,29 @@ on:
type: string
required: true
default: test
refreshToken:
description: Refresh token"
type: string
required: true
idToken:
description: Refresh token"
type: string
required: true

jobs:
docker:
runs-on: ubuntu-latest
steps:
- name: Mask token
run: |
REFRESH_TOKEN=$(jq -r '.inputs.refreshToken' $GITHUB_EVENT_PATH)
echo ::add-mask::$REFRESH_TOKEN
echo REFRESH_TOKEN=$REFRESH_TOKEN >> $GITHUB_ENV
ID_TOKEN=$(jq -r '.inputs.idToken' $GITHUB_EVENT_PATH)
echo ::add-mask::$ID_TOKEN
echo ID_TOKEN=$ID_TOKEN >> $GITHUB_ENV
- uses: actions/checkout@v2

- name: yq - portable yaml processor
uses: mikefarah/[email protected]
- name: Set image name
Expand Down Expand Up @@ -74,8 +90,8 @@ jobs:
--auth-provider=oidc \
--auth-provider-arg=idp-issuer-url=https://auth.lab.sspcloud.fr/auth/realms/sspcloud \
--auth-provider-arg=client-id=onyxia \
--auth-provider-arg=refresh-token=${{ secrets.ONYXIA_REFRESH_TOKEN }} \
--auth-provider-arg=id-token=${{ secrets.ONYXIA_ID_TOKEN }}
--auth-provider-arg=refresh-token=${{ env.REFRESH_TOKEN }} \
--auth-provider-arg=id-token=${{ env.ID_TOKEN }}
kubectl config set-context apiserver.kub.sspcloud.fr \
--user=${{ secrets.ONYXIA_USERNAME }} \
Expand Down

0 comments on commit 5579804

Please sign in to comment.