From 46bfbaada14ca8af07aef77ece434062142e12a4 Mon Sep 17 00:00:00 2001 From: Geoff Bourne Date: Fri, 12 Mar 2021 09:27:44 -0600 Subject: [PATCH 1/7] Upgraded mc-monitor to 0.7.1 to fix ProtocolSupport response #796 --- Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 366c5063..5f20af35 100644 --- a/Dockerfile +++ b/Dockerfile @@ -51,7 +51,7 @@ RUN easy-add --var os=${TARGETOS} --var arch=${TARGETARCH}${TARGETVARIANT} \ --from https://github.com/itzg/{{.app}}/releases/download/{{.version}}/{{.app}}_{{.version}}_{{.os}}_{{.arch}}.tar.gz RUN easy-add --var os=${TARGETOS} --var arch=${TARGETARCH}${TARGETVARIANT} \ - --var version=0.7.0 --var app=mc-monitor --file {{.app}} \ + --var version=0.7.1 --var app=mc-monitor --file {{.app}} \ --from https://github.com/itzg/{{.app}}/releases/download/{{.version}}/{{.app}}_{{.version}}_{{.os}}_{{.arch}}.tar.gz RUN easy-add --var os=${TARGETOS} --var arch=${TARGETARCH}${TARGETVARIANT} \ From 2bdaa4dc4edcf8675b1e9d495da39555ac1d7ddd Mon Sep 17 00:00:00 2001 From: Geoff Bourne Date: Fri, 12 Mar 2021 17:22:54 -0600 Subject: [PATCH 2/7] Updated java8 warning message for ClassCastException #775 --- start-configuration | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/start-configuration b/start-configuration index 720e0fb7..1a689a1b 100644 --- a/start-configuration +++ b/start-configuration @@ -108,6 +108,8 @@ case "${TYPE^^}" in log "**********************************************************************" log "WARNING: The image tag itzg/minecraft-server:java8 is recommended" log " since some mods require Java 8" + log " Exception traces reporting ClassCastException: class jdk.internal.loader.ClassLoaders\$AppClassLoader" + log " can be fixed with java8" log "**********************************************************************" exec ${SCRIPTS:-/}start-deployForge "$@" ;; @@ -120,6 +122,8 @@ case "${TYPE^^}" in log "**********************************************************************" log "WARNING: The image tag itzg/minecraft-server:java8 is recommended" log " since some mods require Java 8" + log " Exception traces reporting ClassCastException: class jdk.internal.loader.ClassLoaders\$AppClassLoader" + log " can be fixed with java8" log "**********************************************************************" exec ${SCRIPTS:-/}start-deployCF "$@" ;; From d022956e240d29dd65d3ef77ba2134b4a847d598 Mon Sep 17 00:00:00 2001 From: miki164 <32245772+miki164@users.noreply.github.com> Date: Sat, 13 Mar 2021 13:52:14 +0100 Subject: [PATCH 3/7] Fix typo in example docker-compose (#803) --- examples/docker-compose-simple.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/examples/docker-compose-simple.yml b/examples/docker-compose-simple.yml index afb7a35f..f9b0ba40 100644 --- a/examples/docker-compose-simple.yml +++ b/examples/docker-compose-simple.yml @@ -9,4 +9,4 @@ services: EULA: "TRUE" volumes: # attach the relative directory 'data' to the container's /data path - ./data:/data + - ./data:/data From 8d1989a595d4edaf802cf4dfc293219977c60733 Mon Sep 17 00:00:00 2001 From: Geoff Bourne Date: Sat, 13 Mar 2021 16:54:56 -0600 Subject: [PATCH 4/7] docs: Added more info about getbukkit's weird 1.8 file naming #103 --- README.md | 2 ++ start-deployBukkitSpigot | 4 +++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index ff182338..c9ddb7b5 100644 --- a/README.md +++ b/README.md @@ -460,6 +460,8 @@ You can build spigot from source by adding `-e BUILD_FROM_SOURCE=true` If you have attached a host directory to the `/data` volume, then you can install plugins within the `plugins` subdirectory. You can also [attach a `/plugins` volume](#deploying-plugins-from-attached-volume). If you add plugins while the container is running, you'll need to restart it to pick those up. +> NOTE some of the `VERSION` values are not as intuitive as you would think, so make sure to click into the version entry to find the **exact** version needed for the download. For example, "1.8" is not sufficient since their download naming expects `1.8-R0.1-SNAPSHOT-latest` exactly. + ## Running a Paper server Enable Paper server mode by adding a `-e TYPE=PAPER` to your command-line. diff --git a/start-deployBukkitSpigot b/start-deployBukkitSpigot index 37b59269..023d87b2 100644 --- a/start-deployBukkitSpigot +++ b/start-deployBukkitSpigot @@ -82,7 +82,9 @@ function downloadSpigot { ERROR: failed to download from $downloadUrl Visit https://getbukkit.org/download/${getbukkitFlavor} to lookup the - exact version, such as 1.4.6-R0.4-SNAPSHOT or 1.8-R0.1-SNAPSHOT-LATEST + exact version, such as 1.4.6-R0.4-SNAPSHOT or 1.8-R0.1-SNAPSHOT-latest. + Click into the version entry to find the **exact** version, because something + like "1.8" is not sufficient according to their download naming. EOF From 28810fcba3e85415b4beca42a908238ee3a3eb3d Mon Sep 17 00:00:00 2001 From: Geoff Bourne Date: Sun, 14 Mar 2021 15:02:40 -0500 Subject: [PATCH 5/7] Added support for CF modpacks using settings.cfg #772 #800 --- start-deployCF | 37 +++++++++++++++++++++++++++++++++++-- 1 file changed, 35 insertions(+), 2 deletions(-) diff --git a/start-deployCF b/start-deployCF index 86bd44ca..a881e7bc 100644 --- a/start-deployCF +++ b/start-deployCF @@ -3,6 +3,24 @@ set -e . ${SCRIPTS:-/}start-utils + +loadForgeVars() { + cfgFile=${1?} + pat='^([^#;][^=]+)=[:space:]*([^;]*)' + while read -r line || [[ -n "$line" ]] ; do + if [[ $line =~ $pat ]]; then + #echo "MATCHED $line" + k=${BASH_REMATCH[1]} + v=${BASH_REMATCH[2]} + case $k in + FORGEURL) + forgeInstallerUrl="$v" + ;; + esac + fi + done < "$cfgFile" +} + isDebugging && set -x : ${FTB_BASE_DIR:=${CF_BASE_DIR:-/data/FeedTheBeast}} @@ -44,9 +62,24 @@ if ! isTrue ${USE_MODPACK_START_SCRIPT:-true}; then serverJar=$(find ${FTB_BASE_DIR} -path "*/libraries/*" -prune -type f -o -not -name "forge*installer.jar" -name "forge*.jar") if [[ -z "$serverJar" ]]; then - forgeInstallerJar=$(find ${FTB_BASE_DIR} -name "forge*installer.jar") + + if [ -f "${FTB_BASE_DIR}/settings.cfg" ]; then + loadForgeVars "${FTB_BASE_DIR}/settings.cfg" + + if [[ $forgeInstallerUrl ]]; then + forgeInstallerJar="${FTB_BASE_DIR}/forge-installer.jar" + if ! curl -fsSL -o "$forgeInstallerJar" "$forgeInstallerUrl" ; then + log "ERROR failed to download Forge installer from $forgeInstallerUrl" + exit 2 + fi + fi + else + forgeInstallerJar=$(find ${FTB_BASE_DIR} -name "forge*installer.jar") + fi + if [[ -z "${forgeInstallerJar}" ]]; then - log "ERROR Unable to find forge installer in modpack." + log "ERROR Unable to find forge installer in modpack" + log " or download using modpack config." log " Make sure you downloaded the server files." exit 2 fi From c4b573f608b8fc275ef541fec04dac46864fb564 Mon Sep 17 00:00:00 2001 From: Geoff Bourne Date: Sun, 14 Mar 2021 16:18:43 -0500 Subject: [PATCH 6/7] docs: Clarified disabling of max tick watchdog for autopause #555 --- README.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index c9ddb7b5..0d20a9f6 100644 --- a/README.md +++ b/README.md @@ -217,7 +217,9 @@ An autopause functionality has been added to this image to monitor whether clien Of course, even loaded chunks are not ticked when the process is stopped. -From the server's point of view, the pausing causes a single tick to take as long as the process is stopped, so the server watchdog might intervene after the process is continued, possibly forcing a container restart. To prevent this, ensure that the `max-tick-time` in the `server.properties` file is set correctly. Non-vanilla versions might have their own configuration file, you might have to disable their watchdogs separately (e.g. PAPER Servers). +**You must greatly increase or disable max-tick-time watchdog functionality.** From the server's point of view, the pausing causes a single tick to take as long as the process is stopped, so the server watchdog might intervene after the process is continued, possibly forcing a container restart. To prevent this, ensure that the `max-tick-time` in the `server.properties` file is set to a very large value or -1 to disable it entirely, which is highly recommended. That can be set with `MAX_TICK_TIME` as described in [the section below](#max-tick-time). + +> **NOTE:** Non-vanilla versions might have their own configuration file, you might have to disable their watchdogs separately (e.g. PAPER Servers). On startup the `server.properties` file is checked and, if applicable, a warning is printed to the terminal. When the server is created (no data available in the persistent directory), the properties file is created with the Watchdog disabled. From c31b191b9634b9a0cd0fba52f68150313846f6ee Mon Sep 17 00:00:00 2001 From: Geoff Bourne Date: Thu, 18 Mar 2021 19:56:40 -0500 Subject: [PATCH 7/7] Removed "dot output" when running forge installer for CF modpacks #800 --- start-deployCF | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/start-deployCF b/start-deployCF index a881e7bc..ecff5e0a 100644 --- a/start-deployCF +++ b/start-deployCF @@ -74,7 +74,7 @@ if ! isTrue ${USE_MODPACK_START_SCRIPT:-true}; then fi fi else - forgeInstallerJar=$(find ${FTB_BASE_DIR} -name "forge*installer.jar") + forgeInstallerJar=$(find "${FTB_BASE_DIR}" -name "forge*installer.jar") fi if [[ -z "${forgeInstallerJar}" ]]; then @@ -85,7 +85,7 @@ if ! isTrue ${USE_MODPACK_START_SCRIPT:-true}; then fi log "Installing forge server" - (cd $(dirname "${forgeInstallerJar}"); java -jar $(basename "${forgeInstallerJar}") --installServer) | awk '{printf "."} END {print ""}' + (cd $(dirname "${forgeInstallerJar}"); java -jar $(basename "${forgeInstallerJar}") --installServer) fi echo "${FTB_SERVER_MOD}" > $installMarker