refactor: improve Gitea registry login step by adding username variable and logging
Some checks failed
Build and Push Docker Image / docker (push) Failing after 5s
Some checks failed
Build and Push Docker Image / docker (push) Failing after 5s
This commit is contained in:
@@ -121,8 +121,12 @@ jobs:
|
|||||||
- name: Log in to Gitea Registry
|
- name: Log in to Gitea Registry
|
||||||
env:
|
env:
|
||||||
REGISTRY: ${{ steps.vars.outputs.registry }}
|
REGISTRY: ${{ steps.vars.outputs.registry }}
|
||||||
|
REGISTRY_USERNAME: ${{ secrets.REGISTRY_USERNAME }}
|
||||||
run: |
|
run: |
|
||||||
echo "${{ secrets.GITEA_TOKEN }}" | docker login "$REGISTRY" -u "$GITHUB_ACTOR" --password-stdin
|
set -eu
|
||||||
|
USER_NAME="${REGISTRY_USERNAME:-$GITHUB_ACTOR}"
|
||||||
|
echo "Logging into $REGISTRY as $USER_NAME"
|
||||||
|
echo "${{ secrets.GITEA_TOKEN }}" | docker login "$REGISTRY" -u "$USER_NAME" --password-stdin
|
||||||
|
|
||||||
- name: Ensure buildx builder
|
- name: Ensure buildx builder
|
||||||
run: |
|
run: |
|
||||||
|
|||||||
Reference in New Issue
Block a user