Skip to content

Commit 52865e4

Browse files
committed
I love github actions
1 parent d16626c commit 52865e4

File tree

1 file changed

+10
-4
lines changed

1 file changed

+10
-4
lines changed

.github/workflows/release.yml

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,9 @@ jobs:
1616
- name: Get the version
1717
id: get_version
1818
run: echo "VERSION=${GITHUB_REF#refs/tags/}" >> $GITHUB_OUTPUT
19+
- name: downcase REPO
20+
id: lower_repo
21+
run: echo "REPO=${GITHUB_REPOSITORY@L}" >> "$GITHUB_OUTPUT"
1922

2023
- name: Log in to GitHub Container Registry
2124
uses: docker/login-action@v2
@@ -31,8 +34,8 @@ jobs:
3134
file: ./shepherd_server/Dockerfile
3235
push: true
3336
tags: |
34-
ghcr.io/${{ toLower(github.repository) }}/shepherd_server:latest
35-
ghcr.io/${{ toLower(github.repository) }}/shepherd_server:${{ steps.get_version.outputs.VERSION }}
37+
ghcr.io/${{ steps.lower_repo.outputs.REPO }}/shepherd_server:latest
38+
ghcr.io/${{ steps.lower_repo.outputs.REPO }}/shepherd_server:${{ steps.get_version.outputs.VERSION }}
3639
3740
push_workers_to_registry:
3841
name: Push Docker image to GitHub Packages tagged with "latest" and version number.
@@ -48,6 +51,9 @@ jobs:
4851
- name: Get the version
4952
id: get_version
5053
run: echo "VERSION=${GITHUB_REF#refs/tags/}" >> $GITHUB_OUTPUT
54+
- name: downcase REPO
55+
id: lower_repo
56+
run: echo "REPO=${GITHUB_REPOSITORY@L}" >> "$GITHUB_OUTPUT"
5157

5258
- name: Log in to GitHub Container Registry
5359
uses: docker/login-action@v2
@@ -63,5 +69,5 @@ jobs:
6369
file: ./workers/${{ matrix.worker }}/Dockerfile
6470
push: true
6571
tags: |
66-
ghcr.io/${{ toLower(github.repository) }}/${{ matrix.worker }}:latest
67-
ghcr.io/${{ toLower(github.repository) }}/${{ matrix.worker }}:${{ steps.get_version.outputs.VERSION }}
72+
ghcr.io/${{ steps.lower_repo.outputs.REPO }}/${{ matrix.worker }}:latest
73+
ghcr.io/${{ steps.lower_repo.outputs.REPO }}/${{ matrix.worker }}:${{ steps.get_version.outputs.VERSION }}

0 commit comments

Comments
 (0)