[FORGEJO] secrets are trimmed from output, cope with it
This commit is contained in:
parent
c9ea086e40
commit
6f8ca39fa4
2 changed files with 17 additions and 2 deletions
|
@ -52,3 +52,4 @@ jobs:
|
|||
curl -L -sS $url/root/runner/releases/download/v1.2.3/forgejo-runner-amd64 > forgejo-runner
|
||||
chmod +x forgejo-runner
|
||||
./forgejo-runner --version | grep 1.2.3
|
||||
|
||||
|
|
|
@ -74,7 +74,9 @@ jobs:
|
|||
${{ steps.registry.outputs.buildx-config }}
|
||||
|
||||
- run: |
|
||||
BASE64_AUTH=`echo -n "${{ steps.secrets.outputs.doer }}:${{ steps.secrets.outputs.token }}" | base64`
|
||||
token="${{ steps.secrets.outputs.token }}" ; test -z "$token" && token="${{ secrets.TOKEN }}"
|
||||
doer="${{ steps.secrets.outputs.doer }}" ; test -z "$doer" && doer="${{ secrets.DOER }}"
|
||||
BASE64_AUTH=`echo -n "$doer:$token" | base64`
|
||||
mkdir -p ~/.docker
|
||||
echo "{\"auths\": {\"$CI_REGISTRY\": {\"auth\": \"$BASE64_AUTH\"}}}" > ~/.docker/config.json
|
||||
env:
|
||||
|
@ -105,10 +107,22 @@ jobs:
|
|||
docker rm runner
|
||||
done
|
||||
|
||||
- uses: https://code.forgejo.org/actions/forgejo-release@v1
|
||||
- name: publish release (when TOKEN secret is NOT set)
|
||||
if: ${{ secrets.TOKEN == '' }}
|
||||
uses: https://code.forgejo.org/actions/forgejo-release@v1
|
||||
with:
|
||||
direction: upload
|
||||
release-dir: release
|
||||
release-notes: "RELEASE-NOTES#${{ steps.build.outputs.tag }}"
|
||||
token: ${{ steps.secrets.outputs.token }}
|
||||
verbose: ${{ steps.verbose.outputs.value }}
|
||||
|
||||
- name: publish release (when TOKEN secret is set)
|
||||
if: ${{ secrets.TOKEN != '' }}
|
||||
uses: https://code.forgejo.org/actions/forgejo-release@v1
|
||||
with:
|
||||
direction: upload
|
||||
release-dir: release
|
||||
release-notes: "RELEASE-NOTES#${{ steps.build.outputs.tag }}"
|
||||
token: ${{ secrets.TOKEN }}
|
||||
verbose: ${{ steps.verbose.outputs.value }}
|
||||
|
|
Loading…
Reference in a new issue