From e2d63359ca5e74b91d569e1e8c02ca0ff8ea9c24 Mon Sep 17 00:00:00 2001 From: Lilith <9@korewa.li> Date: Mon, 28 Sep 2026 19:20:03 +0700 Subject: [PATCH 01/10] feat: Deploy script for Cleanroom Loader --- scripts/start-deployCleanroom | 50 +++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) create mode 100644 scripts/start-deployCleanroom diff --git a/scripts/start-deployCleanroom b/scripts/start-deployCleanroom new file mode 100644 index 00000000000..e202e5bcf0a --- /dev/null +++ b/scripts/start-deployCleanroom @@ -0,0 +1,50 @@ +#!/bin/bash + +: "${CLEANROOM_LOADER_VERSION:=${CLEANROOMLOADERVERSION:LATEST}}" +: "${CLEANROOM_INSTALLER_VERSION:=${CLEANROOMINSTALLERVERSION:LATEST}}" +: "${CLEANROOM_FORCE_REINSTALL:=false}" + +# shellcheck source=start-utils +. "${SCRIPTS:-$(dirname "$0")}/start-utils" +isDebugging && set -x +resultsFile=/data/.run-cleanroom.env + +function mc-image-helper-cleanroom() { + mc-image-helper install-cleanroom \ + --output-directory=/data \ + --results-file="${resultsFile}" \ + --cleanroom-version="${CLEANROOM_LOADER_VERSION}" \ + --force-reinstall="${CLEANROOM_FORCE_REINSTALL}" "$@" +} + +if [[ ${CLEANROOM_INSTALLER} ]]; then + if ! mc-image-helper-cleanroom --cleanroom-installer="${CLEANROOM_INSTALLER}" ; then + logError "Failed to install Cleanroom given installer ${CLEANROOM_INSTALLER}" + exit 1 + fi +elif [[ ${CLEANROOM_INSTALLER_URL:-} ]]; then + mkdir -p tmp + if ! installer=$(get -o tmp --output-filename "${CLEANROOM_INSTALLER_URL}"); then + logError "Failed to download installer from $CLEANROOM_INSTALLER_URL" + exit 1 + fi + + # shellcheck disable=SC2064 + trap "rm $installer" EXIT + + if ! mc-image-helper-cleanroom --cleanroom-installer="${installer}" ; then + logError "Failed to install Cleanroom from ${CLEANROOM_INSTALLER_URL}" + exit 1 + fi +else + if ! mc-image-helper-cleanroom --installer-version="${CLEANROOM_INSTALLER_VERSION}"; then + logError "Failed to install Cleanroom" + exit 1 + fi +fi + +applyResultsFile ${resultsFile} + +export FAMILY=CLEANROOM + +exec "$(dirname "$0")/start-setupWorld" "$@" From 7c8926118a2d5d72fe82e68b65f6bbaf2ecfb7cd Mon Sep 17 00:00:00 2001 From: Lilith <9@korewa.li> Date: Mon, 28 Sep 2026 19:21:53 +0700 Subject: [PATCH 02/10] feat: allow Cleanroom to be deployable --- scripts/start-configuration | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/scripts/start-configuration b/scripts/start-configuration index 48f47475d9b..eb531377f4b 100755 --- a/scripts/start-configuration +++ b/scripts/start-configuration @@ -283,6 +283,10 @@ case "${TYPE^^}" in exec "$(dirname "$0")/start-deployForge" "$@" ;; + CLEANROOM) + exec "$(dirname "$0")/start-deployCleanroom" "$@" + ;; + NEOFORGE|NEOFORGED) exec "$(dirname "$0")/start-deployNeoForge" "$@" ;; @@ -363,7 +367,8 @@ case "${TYPE^^}" in logError "Invalid TYPE: '$TYPE'" logError "Must be: VANILLA, FORGE, BUKKIT, SPIGOT, PAPER, FOLIA, PURPUR, FABRIC, QUILT," logError " SPONGEVANILLA, CUSTOM, MAGMA, MOHIST, GTNH, AIRPLANE, PUFFERFISH," - logError " CANYON, LIMBO, NANOLIMBO, CRUCIBLE, LEAF, YOUER, BANNER, NEOFORGE" + logError " CANYON, LIMBO, NANOLIMBO, CRUCIBLE, LEAF, YOUER, BANNER, NEOFORGE," + logError " CLEANROOM" exit 1 ;; From c0d173adaf67bbb35824107df40ee17b75f908ca Mon Sep 17 00:00:00 2001 From: Lilith <9@korewa.li> Date: Mon, 28 Sep 2026 19:25:42 +0700 Subject: [PATCH 03/10] feat: Missing bracket :skull: --- scripts/start-deployCleanroom | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/start-deployCleanroom b/scripts/start-deployCleanroom index e202e5bcf0a..37c1ee67465 100644 --- a/scripts/start-deployCleanroom +++ b/scripts/start-deployCleanroom @@ -25,7 +25,7 @@ if [[ ${CLEANROOM_INSTALLER} ]]; then elif [[ ${CLEANROOM_INSTALLER_URL:-} ]]; then mkdir -p tmp if ! installer=$(get -o tmp --output-filename "${CLEANROOM_INSTALLER_URL}"); then - logError "Failed to download installer from $CLEANROOM_INSTALLER_URL" + logError "Failed to download installer from ${CLEANROOM_INSTALLER_URL}" exit 1 fi From 3734c8e65440445c207aeb57f4f0d87e6de36d83 Mon Sep 17 00:00:00 2001 From: Lilith <9@korewa.li> Date: Tue, 6 Oct 2026 13:17:29 +0700 Subject: [PATCH 04/10] feat: new install script for Cleanroom --- scripts/start-deployCleanroom | 60 ++++++++++++++++------------------- 1 file changed, 28 insertions(+), 32 deletions(-) diff --git a/scripts/start-deployCleanroom b/scripts/start-deployCleanroom index 37c1ee67465..ead27a4d31b 100644 --- a/scripts/start-deployCleanroom +++ b/scripts/start-deployCleanroom @@ -1,7 +1,5 @@ #!/bin/bash -: "${CLEANROOM_LOADER_VERSION:=${CLEANROOMLOADERVERSION:LATEST}}" -: "${CLEANROOM_INSTALLER_VERSION:=${CLEANROOMINSTALLERVERSION:LATEST}}" : "${CLEANROOM_FORCE_REINSTALL:=false}" # shellcheck source=start-utils @@ -9,42 +7,40 @@ isDebugging && set -x resultsFile=/data/.run-cleanroom.env -function mc-image-helper-cleanroom() { - mc-image-helper install-cleanroom \ - --output-directory=/data \ - --results-file="${resultsFile}" \ - --cleanroom-version="${CLEANROOM_LOADER_VERSION}" \ - --force-reinstall="${CLEANROOM_FORCE_REINSTALL}" "$@" -} - -if [[ ${CLEANROOM_INSTALLER} ]]; then - if ! mc-image-helper-cleanroom --cleanroom-installer="${CLEANROOM_INSTALLER}" ; then - logError "Failed to install Cleanroom given installer ${CLEANROOM_INSTALLER}" - exit 1 - fi -elif [[ ${CLEANROOM_INSTALLER_URL:-} ]]; then - mkdir -p tmp - if ! installer=$(get -o tmp --output-filename "${CLEANROOM_INSTALLER_URL}"); then - logError "Failed to download installer from ${CLEANROOM_INSTALLER_URL}" - exit 1 - fi +declare -a cleanroom_installer_options +cleanroom_installer_options+=(--output-directory=/data) +cleanroom_installer_options+=(--results-file="${resultsFile}") +cleanroom_installer_options+=(--force-reinstall="${CLEANROOM_FORCE_REINSTALL}") - # shellcheck disable=SC2064 - trap "rm $installer" EXIT +if [[ ${CLEANROOM_LOADER_VERSION} ]]; then + cleanroom_installer_options+=(--loader-version=${CLEANROOM_LOADER_VERSION}) +fi - if ! mc-image-helper-cleanroom --cleanroom-installer="${installer}" ; then - logError "Failed to install Cleanroom from ${CLEANROOM_INSTALLER_URL}" - exit 1 - fi -else - if ! mc-image-helper-cleanroom --installer-version="${CLEANROOM_INSTALLER_VERSION}"; then +if [[ ${CLEANROOM_INSTALLER_VERSION} ]]; then + cleanroom_installer_options+=(--installer-version=${CLEANROOM_INSTALLER_VERSION}) +fi + +if [[ ${CLEANROOM_FROM_FILE} ]]; then + cleanroom_installer_options+=(--from-local-file=${CLEANROOM_FROM_FILE}) +fi + +if [[ ${CLEANROOM_FROM_URL} ]]; then + cleanroom_installer_options+=(--from-url=${CLEANROOM_FROM_URL}) +fi + +if ! mc-image-helper install-cleanroom "${cleanroom_installer_options[@]}" ; then + if [[ ${CLEANROOM_FROM_FILE} ]]; then + logError "Failed to install Cleanroom given installer ${CLEANROOM_FROM_FILE}" + elif [[ ${CLEANROOM_FROM_URL:-} ]]; then + logError "Failed to install Cleanroom from ${CLEANROOM_FROM_URL}" + else logError "Failed to install Cleanroom" - exit 1 - fi + fi + exit 1 fi applyResultsFile ${resultsFile} -export FAMILY=CLEANROOM +export FAMILY=FORGE exec "$(dirname "$0")/start-setupWorld" "$@" From 4aba694ab5d00cedfd7682bc0b0b48282e9d47e1 Mon Sep 17 00:00:00 2001 From: Lilith <9@korewa.li> Date: Tue, 6 Oct 2026 13:20:54 +0700 Subject: [PATCH 05/10] feat: add missing quotation marks --- scripts/start-deployCleanroom | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/scripts/start-deployCleanroom b/scripts/start-deployCleanroom index ead27a4d31b..ba975cb8268 100644 --- a/scripts/start-deployCleanroom +++ b/scripts/start-deployCleanroom @@ -13,19 +13,19 @@ cleanroom_installer_options+=(--results-file="${resultsFile}") cleanroom_installer_options+=(--force-reinstall="${CLEANROOM_FORCE_REINSTALL}") if [[ ${CLEANROOM_LOADER_VERSION} ]]; then - cleanroom_installer_options+=(--loader-version=${CLEANROOM_LOADER_VERSION}) + cleanroom_installer_options+=(--loader-version="${CLEANROOM_LOADER_VERSION}") fi if [[ ${CLEANROOM_INSTALLER_VERSION} ]]; then - cleanroom_installer_options+=(--installer-version=${CLEANROOM_INSTALLER_VERSION}) + cleanroom_installer_options+=(--installer-version="${CLEANROOM_INSTALLER_VERSION}") fi if [[ ${CLEANROOM_FROM_FILE} ]]; then - cleanroom_installer_options+=(--from-local-file=${CLEANROOM_FROM_FILE}) + cleanroom_installer_options+=(--from-local-file="${CLEANROOM_FROM_FILE}") fi if [[ ${CLEANROOM_FROM_URL} ]]; then - cleanroom_installer_options+=(--from-url=${CLEANROOM_FROM_URL}) + cleanroom_installer_options+=(--from-url="${CLEANROOM_FROM_URL}") fi if ! mc-image-helper install-cleanroom "${cleanroom_installer_options[@]}" ; then From 28b9a5225f424749050cd898928c4fd351cc1a06 Mon Sep 17 00:00:00 2001 From: Lilith <9@korewa.li> Date: Tue, 6 Oct 2026 13:59:35 +0700 Subject: [PATCH 06/10] feat: add specific document for Cleanroom --- .../server-types/cleanroom.md | 67 +++++++++++++++++++ 1 file changed, 67 insertions(+) create mode 100644 docs/types-and-platforms/server-types/cleanroom.md diff --git a/docs/types-and-platforms/server-types/cleanroom.md b/docs/types-and-platforms/server-types/cleanroom.md new file mode 100644 index 00000000000..7ffc80c91f5 --- /dev/null +++ b/docs/types-and-platforms/server-types/cleanroom.md @@ -0,0 +1,67 @@ +A [Cleanroom server](https://cleanroommc.com/) can be automatically downloaded, upgraded, and run by setting the environment variable `TYPE` to "CLEANROOM". + +!!! example + + ```shell + docker run -e TYPE=CLEANROOM ... + ``` + + or in a compose file + ```yaml + environment: + TYPE: CLEANROOM + ``` + +Cleanroom is a loader specified for Minecraft 1.12.2, since then `VERSION` will be ignored. By default, the latest version of Cleanroom will be selected. You can also choose a specific Cleanroom version by setting `CLEANROOM_LOADER_VERSION` with that version, such as "0.6.13-alpha". + +!!! example + + ```shell + docker run -e TYPE=CLEANROOM -e CLEANROOM_LOADER_VERSION=0.6.13-alpha -e CLEANROOM_INSTALLER_VERSION=0.1.4 ... + ``` + + or in a compose file + ```yaml + environment: + TYPE: CLEANROOM + CLEANROOM_LOADER_VERSION: "0.6.13-alpha" + ``` + +You can also specify installer version. By default, the latest version of installer will be selected. You can also choose a specific installer version by setting `CLEANROOM_INSTALLER_VERSION` with that version, such as "0.1.4". + +!!! example + + ```shell + docker run -e TYPE=CLEANROOM -e CLEANROOM_INSTALLER_VERSION=0.1.4 ... + ``` + + or in a compose file + ```yaml + environment: + TYPE: CLEANROOM + CLEANROOM_INSTALLER_VERSION: "0.1.4" + ``` + +!!! note + + You do not need to setup this unless required. The installer come from Cleanroom support multi-version installation compare to legacy installer. + +To use a pre-downloaded Cleanroom installer, place it in a location mounted into the container and specify the container path with `CLEANROOM_FROM_FILE`. To download a Cleanroom installer from a custom location, such as your own file repository, specify the URL with `CLEANROOM_FROM_URL`. + +In both of the cases above, there is no need for the `CLEANROOM_LOADER_VERSION` or `CLEANROOM_INSTALLER_VERSION` variables. + +!!! note + + By default, legacy installer are supported but limited support will be provided if asked. + +!!! note + + If an error occurred while installing Cleanroom, it might be possible to resolve by temporarily setting `CLEANROOM_FORCE_REINSTALL` to "true". Be sure to remove that variable after successfully starting the server. + +Specified installer version is configurable via environment variables: + +- `CLEANROOM_INSTALLER_VERSION`: used to specific installer version, default is latest + +URLs configurable via environment variables: + +- `CLEANROOM_MAVEN_URL`: default is https://maven.cleanroommc.com From 3f684cfc67c37e61e5383b401727197c110c1c3c Mon Sep 17 00:00:00 2001 From: Lilith <9@korewa.li> Date: Tue, 6 Oct 2026 14:03:20 +0700 Subject: [PATCH 07/10] feat: remove wrong env on example --- docs/types-and-platforms/server-types/cleanroom.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/types-and-platforms/server-types/cleanroom.md b/docs/types-and-platforms/server-types/cleanroom.md index 7ffc80c91f5..cec7b5c4538 100644 --- a/docs/types-and-platforms/server-types/cleanroom.md +++ b/docs/types-and-platforms/server-types/cleanroom.md @@ -17,7 +17,7 @@ Cleanroom is a loader specified for Minecraft 1.12.2, since then `VERSION` will !!! example ```shell - docker run -e TYPE=CLEANROOM -e CLEANROOM_LOADER_VERSION=0.6.13-alpha -e CLEANROOM_INSTALLER_VERSION=0.1.4 ... + docker run -e TYPE=CLEANROOM -e CLEANROOM_LOADER_VERSION=0.6.13-alpha ... ``` or in a compose file From 857fa1bccb756ca19c26e7a49c52387f851a2d8d Mon Sep 17 00:00:00 2001 From: Lilith <9@korewa.li> Date: Tue, 6 Oct 2026 20:24:10 +0700 Subject: [PATCH 08/10] feat: update Cleanroom docker compose example to use new server type --- examples/cleanroom/compose.yml | 31 ++++++++++++++++++++++++------- 1 file changed, 24 insertions(+), 7 deletions(-) diff --git a/examples/cleanroom/compose.yml b/examples/cleanroom/compose.yml index 8c4c803e742..dca9c6433a2 100644 --- a/examples/cleanroom/compose.yml +++ b/examples/cleanroom/compose.yml @@ -3,13 +3,30 @@ services: mc: image: itzg/minecraft-server - environment: - EULA: true - TYPE: FORGE - FORGE_INSTALLER_URL: https://github.com/CleanroomMC/Cleanroom/releases/download/0.2.4-alpha/cleanroom-0.2.4-alpha-installer.jar ports: - - "25565:25565" + # expose the Minecraft server port outside of container + - "25565:25565" + environment: + # REQUIRED for all types + EULA: "TRUE" + + # Set server type (vs the default of vanilla) + TYPE: CLEANROOM + DEBUG: "true" + + # Optional (check doc for usage) + # CLEANROOM_LOADER_VERSION: 0.0.0-alpha + # CLEANROOM_INSTALLER_VERSION: 0.1.4 + # Using either follow env will ignore 2 above + # CLEANROOM_FROM_LOCAL: ./installer.jar + # CLEANROOM_FROM_URL: https:// volumes: - - mc-data:/data + # use a named, managed volume for data volume + - mc_data:/data + # attach local host directory "mods" in same directory as this compose file + # all mods in this directory get copied into /data/mods at startup + - ./mods:/mods:ro + volumes: - mc-data: \ No newline at end of file + # declared the named volume, but use default/local storage engine + mc-data: {} From d6f88106a8db5d701693e7d11624999c0ba3f593 Mon Sep 17 00:00:00 2001 From: Lilith <9@korewa.li> Date: Tue, 6 Oct 2026 20:26:12 +0700 Subject: [PATCH 09/10] chore: missing tab... really github... --- examples/cleanroom/compose.yml | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/examples/cleanroom/compose.yml b/examples/cleanroom/compose.yml index dca9c6433a2..5539079b24e 100644 --- a/examples/cleanroom/compose.yml +++ b/examples/cleanroom/compose.yml @@ -4,8 +4,8 @@ services: mc: image: itzg/minecraft-server ports: - # expose the Minecraft server port outside of container - - "25565:25565" + # expose the Minecraft server port outside of container + - "25565:25565" environment: # REQUIRED for all types EULA: "TRUE" @@ -21,11 +21,11 @@ services: # CLEANROOM_FROM_LOCAL: ./installer.jar # CLEANROOM_FROM_URL: https:// volumes: - # use a named, managed volume for data volume - - mc_data:/data - # attach local host directory "mods" in same directory as this compose file - # all mods in this directory get copied into /data/mods at startup - - ./mods:/mods:ro + # use a named, managed volume for data volume + - mc_data:/data + # attach local host directory "mods" in same directory as this compose file + # all mods in this directory get copied into /data/mods at startup + - ./mods:/mods:ro volumes: # declared the named volume, but use default/local storage engine From f441ecf5b698113166c67dc4d0d540db5d485f31 Mon Sep 17 00:00:00 2001 From: Lilith <9@korewa.li> Date: Tue, 6 Oct 2026 20:47:27 +0700 Subject: [PATCH 10/10] feat: add missing option to change maven URL --- scripts/start-deployCleanroom | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/scripts/start-deployCleanroom b/scripts/start-deployCleanroom index ba975cb8268..cb50b7b4282 100644 --- a/scripts/start-deployCleanroom +++ b/scripts/start-deployCleanroom @@ -28,6 +28,10 @@ if [[ ${CLEANROOM_FROM_URL} ]]; then cleanroom_installer_options+=(--from-url="${CLEANROOM_FROM_URL}") fi +if [[ ${CLEANROOM_MAVEN_URL} ]]; then + cleanroom_installer_options+=(--cleanroom-maven-url="${CLEANROOM_MAVEN_URL}") +fi + if ! mc-image-helper install-cleanroom "${cleanroom_installer_options[@]}" ; then if [[ ${CLEANROOM_FROM_FILE} ]]; then logError "Failed to install Cleanroom given installer ${CLEANROOM_FROM_FILE}"