build_push.sh: show current tag, offer to set new one before build

This commit is contained in:
Oliver Hofmann 2026-04-29 09:36:50 +02:00
parent 9910e6e062
commit 222b204d4b

View File

@ -5,13 +5,23 @@ cd "$(dirname "$0")"
IMAGE=mediaeng/llmproxy
PLATFORM=linux/arm64
VERSION=$(git describe --tags --always)
if [ -z "$VERSION" ]; then
CURRENT=$(git describe --tags --always)
if [ -z "$CURRENT" ]; then
echo "Fehler: git describe liefert kein Ergebnis"
exit 1
fi
echo "Version : $VERSION"
echo "Aktueller Tag: $CURRENT"
read -rp "Neuer Tag [${CURRENT}]: " INPUT
VERSION="${INPUT:-$CURRENT}"
if [ "$VERSION" != "$CURRENT" ]; then
git tag "$VERSION"
git push origin "$VERSION"
echo "Tag '$VERSION' gesetzt und gepusht."
fi
echo ""
echo "Image : $IMAGE"
echo "Platform: $PLATFORM"
echo "Tags : $IMAGE:$VERSION $IMAGE:latest"