Skip to content

Commit 5a96126

Browse files
committed
build: Add generic tags to container image
This improves the local development experience by providing stable, predictable tags to use for testing, without affecting the architecture-specific tags required by the CI/release process.
1 parent e9b99ba commit 5a96126

File tree

1 file changed

+11
-11
lines changed

1 file changed

+11
-11
lines changed

tools/container-build.sh

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -25,31 +25,31 @@ else
2525
# No override - detect from current machine
2626
MACHINE_ARCH=$(uname -m)
2727
case "${MACHINE_ARCH}" in
28-
x86_64) PLATFORM="linux/amd64" ;;
29-
aarch64) PLATFORM="linux/arm64" ;;
30-
arm64) PLATFORM="linux/arm64" ;;
31-
*) echo "Unsupported machine architecture: ${MACHINE_ARCH}" && exit 1 ;;
28+
x86_64) PLATFORM="linux/amd64" ;;
29+
aarch64) PLATFORM="linux/arm64" ;;
30+
arm64) PLATFORM="linux/arm64" ;;
31+
*) echo "Unsupported machine architecture: ${MACHINE_ARCH}" && exit 1 ;;
3232
esac
3333
fi
3434

3535
# Convert platform to short architecture name for file naming
3636
case "${PLATFORM}" in
37-
linux/amd64) ARCH="amd64" ;;
38-
linux/arm64) ARCH="arm64" ;;
39-
*) echo "Unsupported platform: ${PLATFORM}" && exit 1 ;;
37+
linux/amd64) ARCH="amd64" ;;
38+
linux/arm64) ARCH="arm64" ;;
39+
*) echo "Unsupported platform: ${PLATFORM}" && exit 1 ;;
4040
esac
4141

42-
# Define single tag to avoid collisions and redundancy
43-
TAG="boulder:${VERSION}-${ARCH}"
44-
4542
# Create platform-specific image
43+
# Keep generic tags for standalone use
4644
docker buildx build \
4745
--file Containerfile \
4846
--platform "$PLATFORM" \
4947
--build-arg "COMMIT_ID=${COMMIT_ID}" \
5048
--build-arg "GO_VERSION=${GO_VERSION}" \
5149
--build-arg "VERSION=${VERSION}" \
52-
--tag "${TAG}" \
50+
--tag "boulder:${VERSION}-${ARCH}" \
51+
--tag "boulder:${VERSION}" \
52+
--tag "boulder" \
5353
--load \
5454
--progress=plain \
5555
.

0 commit comments

Comments
 (0)