Skip to content

Commit ecac3ac

Browse files
authored
Fix docker image tagging (#20)
1 parent 5305967 commit ecac3ac

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

.github/workflows/publish.yaml

+7-2
Original file line numberDiff line numberDiff line change
@@ -6,14 +6,15 @@ jobs:
66
push_to_registry:
77
name: Push Docker image to GitHub Packages
88
runs-on: ubuntu-latest
9+
env:
10+
DOCKER_REPO: ghcr.io/spotify/flink-operator
911
steps:
1012
- name: Check out the repo
1113
uses: actions/checkout@v2
1214
- name: Prepare
1315
id: prep
1416
run: |
15-
DOCKER_IMAGE=ghcr.io/spotify/flink-operator:${GITHUB_SHA::8}
16-
echo ::set-output name=image::${DOCKER_IMAGE}
17+
echo ::set-output name=image::${DOCKER_REPO}:${GITHUB_REF/refs\/tags\//}
1718
- name: Login to Github container registry
1819
uses: docker/[email protected]
1920
with:
@@ -24,3 +25,7 @@ jobs:
2425
run: make operator-image push-operator-image
2526
env:
2627
IMG: ${{ steps.prep.outputs.image }}
28+
- name: Tag latest
29+
run: docker tag ${{ steps.prep.outputs.image }} ${DOCKER_REPO}:latest
30+
- name: Push latest
31+
run: docker push ${DOCKER_REPO}:latest

0 commit comments

Comments
 (0)