2021-10-20 01:57:47 +00:00
|
|
|
#!/usr/bin/env bash
|
2021-10-25 18:07:48 +00:00
|
|
|
set -euo pipefail
|
2021-10-20 01:57:47 +00:00
|
|
|
|
2021-11-06 21:11:12 +00:00
|
|
|
VERSION="${1:-$(mvn help:evaluate -Dexpression=project.version -q -DforceStdout)}"
|
2021-10-20 01:57:47 +00:00
|
|
|
|
2021-11-06 21:11:12 +00:00
|
|
|
TAGS=""
|
|
|
|
if [ -n "${IMAGE_TAGS:-}" ]; then
|
|
|
|
TAGS="-Djib.to.tags=${IMAGE_TAGS// /}"
|
|
|
|
fi
|
2021-10-20 01:57:47 +00:00
|
|
|
|
2021-11-06 21:11:12 +00:00
|
|
|
./mvnw -B -ntp -DskipTests "${TAGS}" -Pjib-multi-arch \
|
|
|
|
-Dimage.version="${VERSION}" \
|
|
|
|
-Djib.to.auth.username="${GITHUB_ACTOR}" \
|
|
|
|
-Djib.to.auth.password="${GITHUB_TOKEN}" \
|
|
|
|
package jib:build --file pom.xml
|
2021-10-20 01:57:47 +00:00
|
|
|
|
2022-09-23 01:43:33 +00:00
|
|
|
./mvnw -B -Dgpg.passphrase="${OSSRH_GPG_SECRET_KEY_PASSWORD}" -DskipTests -Prelease -Pflatten deploy
|