Skip to content

Commit 67b8831

Browse files
committed
Update mirror images to take target image name
Allow overwriting the target tag to support mirror images from multiple sources under our single namespace. Signed-off-by: Derek McGowan <[email protected]>
1 parent 0f27a42 commit 67b8831

1 file changed

Lines changed: 9 additions & 1 deletion

File tree

.github/workflows/images.yml

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,9 @@ on:
66
description: "Upstream image to mirror"
77
required: true
88
default: "docker.io/library/busybox:1.32"
9+
image:
10+
description: "Target image name (override)"
11+
912

1013
jobs:
1114
mirror:
@@ -56,7 +59,12 @@ jobs:
5659
sleep 5
5760
5861
upstream=${{ github.event.inputs.upstream }}
59-
mirror="ghcr.io/containerd/${upstream##*/}"
62+
target=${{ github.event.inputs.image }}
63+
if [[ "$target" == "" ]]; then
64+
mirror="ghcr.io/containerd/${upstream##*/}"
65+
else
66+
mirror="ghcr.io/containerd/${target}"
67+
fi
6068
6169
echo "Mirroring $upstream to $mirror"
6270

0 commit comments

Comments
 (0)