mirror of
https://github.com/LibreTranslate/LibreTranslate.git
synced 2024-12-18 08:27:03 +02:00
Fix Docker build failing due to username casing
This commit is contained in:
parent
c217c65358
commit
db34db1688
12
.github/workflows/publish-docker.yml
vendored
12
.github/workflows/publish-docker.yml
vendored
@ -33,9 +33,11 @@ jobs:
|
||||
username: ${{ github.repository_owner }}
|
||||
password: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
- name: Get Version
|
||||
id: get_version
|
||||
run: echo ::set-output name=VERSION::${GITHUB_REF#refs/tags/}
|
||||
- name: Get Variables
|
||||
id: get-variables
|
||||
run: |
|
||||
echo ::set-output name=version::${GITHUB_REF#refs/tags/}
|
||||
echo ::set-output name=gh-username-lower::$(echo ${{ github.repository_owner }} | tr '[:upper:]' '[:lower:]')
|
||||
|
||||
- name: Build and push Image
|
||||
uses: docker/build-push-action@v2
|
||||
@ -43,9 +45,9 @@ jobs:
|
||||
platforms: linux/amd64
|
||||
tags: |
|
||||
${{ secrets.DOCKERHUB_USERNAME }}/libretranslate:${{ env.TAG }},
|
||||
ghcr.io/${{ github.repository_owner }}/libretranslate:${{ env.TAG }}
|
||||
ghcr.io/${{ steps.get-variables.outputs.gh-username-lower }}/libretranslate:${{ env.TAG }}
|
||||
push: true
|
||||
cache-from: type=gha
|
||||
cache-to: type=gha,mode=max
|
||||
env:
|
||||
TAG: ${{ startsWith(github.ref, 'refs/tags/') && steps.get_version.outputs.VERSION || 'latest' }}
|
||||
TAG: ${{ startsWith(github.ref, 'refs/tags/') && steps.get-variables.outputs.version || 'latest' }}
|
||||
|
Loading…
Reference in New Issue
Block a user