docker-minecraft-server/start-deployTuinity

27 lines
773 B
Text
Raw Normal View History

2020-04-24 23:56:15 +00:00
#!/bin/bash
. ${SCRIPTS:-/}start-utils
2020-04-24 23:56:15 +00:00
if [ "${VERSION}" != "LATEST" ]; then
2021-07-06 12:22:01 +00:00
log "ERROR: Tuinity server type only supports VERSION=LATEST"
2020-04-24 23:56:15 +00:00
exit 1
fi
2021-07-06 12:22:01 +00:00
: ${TUINITY_BUILD:=lastSuccessfulBuild}
export SERVER=tuinity-${VANILLA_VERSION}-${TUINITY_BUILD}.jar
2020-04-24 23:56:15 +00:00
if [ ! -f "$SERVER" ] || [ -n "$FORCE_REDOWNLOAD" ]; then
2021-07-06 12:22:01 +00:00
downloadUrl="https://ci.codemc.io/job/Spottedleaf/job/Tuinity/${TUINITY_BUILD}/artifact/tuinity-paperclip.jar"
log "Downloading Tuinity (build $TUINITY_BUILD) from $downloadUrl ..."
2020-04-24 23:56:15 +00:00
curl -fsSL -o "$SERVER" "$downloadUrl"
if [ ! -f "$SERVER" ]; then
log "ERROR: failed to download from $downloadUrl (status=$?)"
exit 3
fi
fi
2021-02-07 17:22:08 +00:00
# Normalize on Spigot for later operations
2020-04-24 23:56:15 +00:00
export TYPE=SPIGOT
exec ${SCRIPTS:-/}start-spiget "$@"