Auto-merging via docker-versions-create

This commit is contained in:
Geoff Bourne 2022-01-08 15:22:43 -06:00
commit 30bd043b46
3 changed files with 13 additions and 4 deletions

View file

@ -139,7 +139,7 @@ By default, the container will download the latest version of the "vanilla" [Min
* [Running on RaspberryPi](#running-on-raspberrypi)
* [Contributing](#contributing)
<!-- Added by: runner, at: Thu Jan 6 12:50:03 UTC 2022 -->
<!-- Added by: runner, at: Sat Jan 8 00:32:28 UTC 2022 -->
<!--te-->
@ -587,6 +587,8 @@ Configuration options with defaults:
- `LIMBO_SCHEMA_FILENAME`=default.schem
- `LEVEL`="Default;${LIMBO_SCHEMA_FILENAME}"
> NOTE: instead of using format codes in the MOTD, Limbo requires [JSON chat content](https://minecraft.fandom.com/wiki/Raw_JSON_text_format#Java_Edition). If a plain string is provided, which is the default, then it gets converted into the required JSON structure.
### Running a Crucible server
A [Crucible](https://github.com/CrucibleMC/Crucible) server can be run by setting `TYPE` to `CRUCIBLE`.

View file

@ -323,10 +323,10 @@ EOF
else
exec mc-server-runner "${mcServerRunnerArgs[@]}" "${finalArgs[@]}"
fi
elif [[ -x run.sh ]]; then
elif [[ $SERVER =~ run.sh ]]; then
log "Using Forge supplied run.sh script..."
echo $JVM_XX_OPTS $JVM_OPTS $expandedDOpts > user_jvm_args.txt
exec mc-server-runner "${mcServerRunnerArgs[@]}" --shell bash run.sh
exec mc-server-runner "${mcServerRunnerArgs[@]}" --shell bash "${SERVER}"
else
# If we have a bootstrap.txt file... feed that in to the server stdin
if [ -f /data/bootstrap.txt ]; then

View file

@ -48,7 +48,7 @@ function customizeServerProps {
# If not provided, generate a reasonable default message-of-the-day,
# which shows up in the server listing in the client
if [ -z "$MOTD" ]; then
if ! [ -v "$MOTD" ]; then
# snapshot is the odd case where we have to look at version to identify that label
if [[ ${ORIGINAL_TYPE} == "VANILLA" && ${VERSION} == "SNAPSHOT" ]]; then
label=SNAPSHOT
@ -62,6 +62,13 @@ function customizeServerProps {
MOTD="A ${label} Minecraft Server powered by Docker"
fi
# normalize MOTD
if [[ ${TYPE^^} = LIMBO ]]; then
if [[ $MOTD ]] && ! [[ $MOTD =~ ^{ ]]; then
MOTD="{\"text\":\"${MOTD}\"}"
fi
fi
setServerProp "server-name" SERVER_NAME
setServerProp "server-ip" SERVER_IP
setServerProp "server-port" SERVER_PORT