Skip to content

Commit 7511745

Browse files
authored
Backport(v1.16): Add more no suffix version tag for k8s (#432)
See #431 Signed-off-by: Kentaro Hayashi <[email protected]>
1 parent 10a94c2 commit 7511745

File tree

2 files changed

+15
-10
lines changed

2 files changed

+15
-10
lines changed

.github/workflows/docker-build.yml

Lines changed: 12 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -72,25 +72,30 @@ jobs:
7272
esac
7373
branch=$(echo $target | cut -d'/' -f1)
7474
tags=$(echo $target | cut -d':' -f2-)
75-
tag1=$(echo $tags | cut -d',' -f1)
76-
tag2=$(echo $tags | cut -d',' -f2)
77-
tag3=$(echo $tags | cut -d',' -f3)
75+
push_tags=""
76+
for tag in $(echo "$tags" | tr , ' '); do
77+
if [ -z "$push_tags" ]; then
78+
push_tags="${{ env.REPOSITORY }}:$tag"
79+
else
80+
push_tags="$push_tags,${{ env.REPOSITORY }}:$tag"
81+
fi
82+
done
7883
case $component in
7984
*alpine*)
8085
echo "CONTEXT=${branch}/${component}" >> ${GITHUB_ENV}
81-
echo "ALPINETAGS=${{ env.REPOSITORY }}:${tag1},${{ env.REPOSITORY }}:${tag2},${{ env.REPOSITORY }}:${tag3}" >> ${GITHUB_ENV}
86+
echo "ALPINETAGS=$push_tags" >> ${GITHUB_ENV}
8287
;;
8388
*arm64*)
8489
echo "CONTEXT=${branch}/${component}/debian" >> ${GITHUB_ENV}
85-
echo "ARM64TAGS=${{ env.REPOSITORY }}:${tag1},${{ env.REPOSITORY }}:${tag2},${{ env.REPOSITORY }}:${tag3}" >> ${GITHUB_ENV}
90+
echo "ARM64TAGS=$push_tags" >> ${GITHUB_ENV}
8691
;;
8792
*armhf*)
8893
echo "CONTEXT=${branch}/${component}/debian" >> ${GITHUB_ENV}
89-
echo "ARMHFTAGS=${{ env.REPOSITORY }}:${tag1},${{ env.REPOSITORY }}:${tag2},${{ env.REPOSITORY }}:${tag3}" >> ${GITHUB_ENV}
94+
echo "ARMHFTAGS=$push_tags" >> ${GITHUB_ENV}
9095
;;
9196
*amd64*)
9297
echo "CONTEXT=${branch}/debian" >> ${GITHUB_ENV}
93-
echo "AMD64TAGS=${{ env.REPOSITORY }}:${tag1},${{ env.REPOSITORY }}:${tag2},${{ env.REPOSITORY }}:${tag3}" >> ${GITHUB_ENV}
98+
echo "AMD64TAGS=$push_tags" >> ${GITHUB_ENV}
9499
;;
95100
esac
96101
done

Makefile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,16 +18,16 @@
1818
IMAGE_NAME := fluent/fluentd
1919
X86_IMAGES := \
2020
v1.16/alpine:v1.16.7-1.1,v1.16-2,edge \
21-
v1.16/debian:v1.16.7-debian-amd64-1.1,v1.16-debian-amd64-2,edge-debian-amd64
21+
v1.16/debian:v1.16.7-debian-amd64-1.1,v1.16-debian-amd64-2,v1.16.7-debian-amd64,edge-debian-amd64
2222
# <Dockerfile>:<version>,<tag1>,<tag2>,...
2323

2424
# Define images for running on ARM platforms
2525
ARM_IMAGES := \
26-
v1.16/armhf/debian:v1.16.7-debian-armhf-1.1,v1.16-debian-armhf-2,edge-debian-armhf \
26+
v1.16/armhf/debian:v1.16.7-debian-armhf-1.1,v1.16-debian-armhf-2,v1.16.7-debian-armhf,edge-debian-armhf \
2727

2828
# Define images for running on ARM64 platforms
2929
ARM64_IMAGES := \
30-
v1.16/arm64/debian:v1.16.7-debian-arm64-1.1,v1.16-debian-arm64-2,edge-debian-arm64 \
30+
v1.16/arm64/debian:v1.16.7-debian-arm64-1.1,v1.16-debian-arm64-2,v1.16.7-debian-arm64,edge-debian-arm64 \
3131

3232
WINDOWS_IMAGES := \
3333
v1.16/windows-ltsc2019:v1.16.7-windows-ltsc2019-1.0,v1.16-windows-ltsc2019-1 \

0 commit comments

Comments
 (0)