2020-04-24 23:56:15 +00:00
|
|
|
#!/bin/bash
|
|
|
|
|
2020-06-19 16:05:32 +00:00
|
|
|
. ${SCRIPTS:-/}start-utils
|
2020-04-24 23:56:15 +00:00
|
|
|
|
|
|
|
if [ "${VERSION}" != "LATEST" ]; then
|
|
|
|
log "ERROR: Tunity server type only supports VERSION=LATEST"
|
|
|
|
exit 1
|
|
|
|
fi
|
|
|
|
|
|
|
|
: ${TUNITY_BUILD:=lastSuccessfulBuild}
|
|
|
|
export SERVER=tunity-${VANILLA_VERSION}-${TUNITY_BUILD}.jar
|
|
|
|
|
|
|
|
if [ ! -f "$SERVER" ] || [ -n "$FORCE_REDOWNLOAD" ]; then
|
|
|
|
downloadUrl="https://ci.codemc.io/job/Spottedleaf/job/Tuinity/${TUNITY_BUILD}/artifact/tuinity-paperclip.jar"
|
|
|
|
log "Downloading Tunity (build $TUNITY_BUILD) from $downloadUrl ..."
|
|
|
|
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
|
|
|
|
|
2021-04-13 01:21:53 +00:00
|
|
|
exec ${SCRIPTS:-/}start-spiget "$@"
|