From 7b7d5db79640c2c08063f879a5a4179c29c738f0 Mon Sep 17 00:00:00 2001 From: Geoff Bourne Date: Thu, 28 Oct 2021 09:10:01 -0500 Subject: [PATCH 01/14] misc: switched to stale action --- .github/no-response.yml | 6 ------ .github/workflows/stale-check.yml | 24 ++++++++++++++++++++++++ 2 files changed, 24 insertions(+), 6 deletions(-) delete mode 100644 .github/no-response.yml create mode 100644 .github/workflows/stale-check.yml diff --git a/.github/no-response.yml b/.github/no-response.yml deleted file mode 100644 index 8618e88c..00000000 --- a/.github/no-response.yml +++ /dev/null @@ -1,6 +0,0 @@ -daysUntilClose: 14 -responseRequiredLabel: "status/waiting on feedback" -closeComment: > - This issue has been automatically closed because there has been no response - after requesting feedback. Please feel free to re-open this issue if the - scenario still exists and provide a comment with more information. \ No newline at end of file diff --git a/.github/workflows/stale-check.yml b/.github/workflows/stale-check.yml new file mode 100644 index 00000000..ed0323d3 --- /dev/null +++ b/.github/workflows/stale-check.yml @@ -0,0 +1,24 @@ +name: Stale Check + +on: + issue_comment: + schedule: + - cron: 0 2 * * * + +jobs: + check: + runs-on: ubuntu-20.04 + permissions: + issues: write + pull-requests: write + steps: + - name: Process Stale Issues + uses: actions/stale@v4.0.0 + with: + stale-issue-message: > + This issue is stale because it has been open 30 days with no activity. + Please add a comment describing the reason to keep this issue open. + days-before-stale: 30 + days-before-close: 5 + exempt-issue-labels: 'enhancement,keep' + From 1a0c7c4f858681ff600a135f4eadb0418b45c793 Mon Sep 17 00:00:00 2001 From: Geoff Bourne Date: Thu, 28 Oct 2021 12:58:39 -0500 Subject: [PATCH 02/14] ci: updated stale status label --- .github/workflows/stale-check.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/stale-check.yml b/.github/workflows/stale-check.yml index ed0323d3..ddb9ef07 100644 --- a/.github/workflows/stale-check.yml +++ b/.github/workflows/stale-check.yml @@ -15,10 +15,12 @@ jobs: - name: Process Stale Issues uses: actions/stale@v4.0.0 with: + stale-issue-label: status/stale + stale-pr-label: status/stale stale-issue-message: > This issue is stale because it has been open 30 days with no activity. Please add a comment describing the reason to keep this issue open. days-before-stale: 30 days-before-close: 5 - exempt-issue-labels: 'enhancement,keep' + exempt-issue-labels: 'enhancement,keep,status/needs triage' From 9803547967a7dc593834425af2d52fed20e4a32c Mon Sep 17 00:00:00 2001 From: Geoff Bourne Date: Thu, 28 Oct 2021 13:24:13 -0500 Subject: [PATCH 03/14] ci: added issue templates --- .github/ISSUE_TEMPLATE/bug.yml | 40 ++++++++++++++++++++++++++ .github/ISSUE_TEMPLATE/enhancement.yml | 31 ++++++++++++++++++++ 2 files changed, 71 insertions(+) create mode 100644 .github/ISSUE_TEMPLATE/bug.yml create mode 100644 .github/ISSUE_TEMPLATE/enhancement.yml diff --git a/.github/ISSUE_TEMPLATE/bug.yml b/.github/ISSUE_TEMPLATE/bug.yml new file mode 100644 index 00000000..8d0f2b83 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/bug.yml @@ -0,0 +1,40 @@ +name: Bug Report +description: File a bug report +labels: + - bug + - status/needs triage +body: + - type: markdown + attributes: + value: | + Thanks for taking the time to report a bug. + + Please double check some things first: + - Do you just have a question about something? If so, asking in the + [Q&A Discussions](https://github.com/itzg/docker-minecraft-server/discussions/categories/q-a) + or asking on [the Discord server](https://discord.gg/DXfKpjB) would be best. + - Is this bug happening after the `[init]` prefixed logs and after the log that says + "Starting the Minecraft server"? If so, please report the bug with Mojang or the + respective server provider. + - Are you seeing a performance problem? If so, that is typically outside the scope of + the image setup mechanims. Ask a question as above or contact the respective server + provider. + - type: textarea + id: problem + attributes: + label: Describe the problem + validations: + required: true + - type: textarea + id: container + attributes: + label: Container definition + description: Please provide the compose file or run command used to create the container + - type: textarea + id: logs + attributes: + label: Container logs + description: | + Please provide container logs from the start of the container, which will be the ones + prefixed with `[init]`. It is even better if you can set the variable `DEBUG` to "true" + and provide those debug container logs. \ No newline at end of file diff --git a/.github/ISSUE_TEMPLATE/enhancement.yml b/.github/ISSUE_TEMPLATE/enhancement.yml new file mode 100644 index 00000000..efe19488 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/enhancement.yml @@ -0,0 +1,31 @@ +name: Enhancement Request +description: Request an enhancement +labels: + - enhancement + - status/needs triage +body: + - type: markdown + attributes: + value: | + Thanks for taking the time to request an enhancement. + + Even if you plan on submitting a pull request with a contributed enhancement it is + best to describe the enhancement here first. Somebody might already be working on + a similar thing and could use your help. + - type: dropdown + id: type + attributes: + label: Enhancement Type + options: + - Improve an existing feature + - A completely new feature + - New server type + - Not sure + validations: + required: true + - type: textarea + id: description + attributes: + label: Describe the enhancement + validations: + required: true \ No newline at end of file From 11ac111036a22a51b45e263467ca80a0ac216d0c Mon Sep 17 00:00:00 2001 From: Geoff Bourne Date: Thu, 28 Oct 2021 13:35:02 -0500 Subject: [PATCH 04/14] ci: tweak formatting in issue templates --- .github/ISSUE_TEMPLATE/bug.yml | 16 ++++------------ .github/ISSUE_TEMPLATE/enhancement.yml | 4 +--- 2 files changed, 5 insertions(+), 15 deletions(-) diff --git a/.github/ISSUE_TEMPLATE/bug.yml b/.github/ISSUE_TEMPLATE/bug.yml index 8d0f2b83..035e7812 100644 --- a/.github/ISSUE_TEMPLATE/bug.yml +++ b/.github/ISSUE_TEMPLATE/bug.yml @@ -10,15 +10,9 @@ body: Thanks for taking the time to report a bug. Please double check some things first: - - Do you just have a question about something? If so, asking in the - [Q&A Discussions](https://github.com/itzg/docker-minecraft-server/discussions/categories/q-a) - or asking on [the Discord server](https://discord.gg/DXfKpjB) would be best. - - Is this bug happening after the `[init]` prefixed logs and after the log that says - "Starting the Minecraft server"? If so, please report the bug with Mojang or the - respective server provider. - - Are you seeing a performance problem? If so, that is typically outside the scope of - the image setup mechanims. Ask a question as above or contact the respective server - provider. + - Do you just have a question about something? If so, asking in the [Q&A Discussions](https://github.com/itzg/docker-minecraft-server/discussions/categories/q-a) or asking on [the Discord server](https://discord.gg/DXfKpjB) would be best. + - Is this bug happening after the `[init]` prefixed logs and after the log that says "Starting the Minecraft server"? If so, please report the bug with Mojang or the respective server provider. + - Are you seeing a performance problem? If so, that is typically outside the scope of the image setup mechanims. Ask a question as above or contact the respective server provider. - type: textarea id: problem attributes: @@ -35,6 +29,4 @@ body: attributes: label: Container logs description: | - Please provide container logs from the start of the container, which will be the ones - prefixed with `[init]`. It is even better if you can set the variable `DEBUG` to "true" - and provide those debug container logs. \ No newline at end of file + Please provide container logs from the start of the container, which will be the ones prefixed with `[init]`. It is even better if you can set the variable `DEBUG` to "true" and provide those debug container logs. \ No newline at end of file diff --git a/.github/ISSUE_TEMPLATE/enhancement.yml b/.github/ISSUE_TEMPLATE/enhancement.yml index efe19488..8b739742 100644 --- a/.github/ISSUE_TEMPLATE/enhancement.yml +++ b/.github/ISSUE_TEMPLATE/enhancement.yml @@ -9,9 +9,7 @@ body: value: | Thanks for taking the time to request an enhancement. - Even if you plan on submitting a pull request with a contributed enhancement it is - best to describe the enhancement here first. Somebody might already be working on - a similar thing and could use your help. + Even if you plan on submitting a pull request with a contributed enhancement it is best to describe the enhancement here first. Somebody might already be working on a similar thing and could use your help. - type: dropdown id: type attributes: From 38fd0dac8be0ad7c32671bc410ce638dfb5426c1 Mon Sep 17 00:00:00 2001 From: Geoff Bourne Date: Thu, 28 Oct 2021 21:31:12 -0500 Subject: [PATCH 05/14] docs: fixed architecture designation of java17 #1074 --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index f8c1e6c2..e44ab1d9 100644 --- a/README.md +++ b/README.md @@ -281,7 +281,7 @@ To use a different version of Java, please use a docker tag to run your Minecraf | java11-openj9 | 11 | Debian | OpenJ9 | amd64 | | java16 | 16 | Debian | Hotspot | amd64,arm64,armv7 | | java16-openj9 | 16 | Debian | OpenJ9 | amd64 | -| java17 | 17 | Ubuntu | Hotspot | amd64 | +| java17 | 17 | Ubuntu | Hotspot | amd64,arm64,armv7 | For example, to use Java version 16 on any supported architecture: From 4fd234e4823929dccfababb8b77fcfd57bf980c8 Mon Sep 17 00:00:00 2001 From: itzg Date: Fri, 29 Oct 2021 02:31:34 +0000 Subject: [PATCH 06/14] docs: Auto update markdown TOC --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index e44ab1d9..72176521 100644 --- a/README.md +++ b/README.md @@ -132,7 +132,7 @@ By default, the container will download the latest version of the "vanilla" [Min * [Enabling Autopause](#enabling-autopause) * [Running on RaspberryPi](#running-on-raspberrypi) - + From 386e34e05b8e2254c62ebbf8539264d9ca12e17a Mon Sep 17 00:00:00 2001 From: Geoff Bourne Date: Fri, 29 Oct 2021 12:34:24 -0500 Subject: [PATCH 07/14] docs: clarified Forge pre-1.17 requirement of Java 8 --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 72176521..bfe872cf 100644 --- a/README.md +++ b/README.md @@ -287,7 +287,7 @@ For example, to use Java version 16 on any supported architecture: docker run --name mc itzg/minecraft-server:java16 -> Keep in mind that some versions of Minecraft server can't work on the newest versions of Java. Also, FORGE doesn't support openj9 JVM implementation. +> Keep in mind that some versions of Minecraft server, such as Forge before 1.17, can't work on the newest versions of Java. Instead, one of the Java 8 images should be used. Also, FORGE doesn't support openj9 JVM implementation. ### Deprecated Image Tags From 3237d1a996d3820bea9ade772d02600dd9bf5922 Mon Sep 17 00:00:00 2001 From: itzg Date: Fri, 29 Oct 2021 17:34:39 +0000 Subject: [PATCH 08/14] docs: Auto update markdown TOC --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index bfe872cf..2342682f 100644 --- a/README.md +++ b/README.md @@ -132,7 +132,7 @@ By default, the container will download the latest version of the "vanilla" [Min * [Enabling Autopause](#enabling-autopause) * [Running on RaspberryPi](#running-on-raspberrypi) - + From 46f6653b1374d14caa604bdbdc9c4192434df72b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20Vorburger=20=E2=9B=91=EF=B8=8F?= Date: Fri, 29 Oct 2021 23:38:17 +0200 Subject: [PATCH 09/14] docs: clarify java8-multiarch tag for TYPE=SPONGEVANILLA in README (#1095) --- README.md | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 2342682f..e21e7df7 100644 --- a/README.md +++ b/README.md @@ -516,11 +516,14 @@ By default the latest build will be used; however, a specific build number can b ### Running a SpongeVanilla server Enable SpongeVanilla server mode by adding a `-e TYPE=SPONGEVANILLA` to your command-line. + By default the container will run the latest `STABLE` version. If you want to run a specific version, you can add `-e SPONGEVERSION=1.11.2-6.1.0-BETA-19` to your command-line. +Beware that current [Sponge](https://www.spongepowered.org) `STABLE` versions for Minecraft 1.12 require using [the Java 8 tag](#running-minecraft-server-on-different-java-version): + docker run -d -v /path/on/host:/data -e TYPE=SPONGEVANILLA \ - -p 25565:25565 -e EULA=TRUE --name mc itzg/minecraft-server + -p 25565:25565 -e EULA=TRUE --name mc itzg/minecraft-server:java8-multiarch You can also choose to use the `EXPERIMENTAL` branch. Just change it with `SPONGEBRANCH`, such as: From afd863ab89c820c1a15515c63e25c034589a8a4d Mon Sep 17 00:00:00 2001 From: itzg Date: Fri, 29 Oct 2021 21:38:33 +0000 Subject: [PATCH 10/14] docs: Auto update markdown TOC --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index e21e7df7..c2feaab8 100644 --- a/README.md +++ b/README.md @@ -132,7 +132,7 @@ By default, the container will download the latest version of the "vanilla" [Min * [Enabling Autopause](#enabling-autopause) * [Running on RaspberryPi](#running-on-raspberrypi) - + From cc8d18d41f5d0a1e0e29f7853b27283d1ac5c1d8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20Vorburger=20=E2=9B=91=EF=B8=8F?= Date: Fri, 29 Oct 2021 23:39:23 +0200 Subject: [PATCH 11/14] docs: add links to Development and Building in README (#1096) --- README.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/README.md b/README.md index c2feaab8..5ca3ed57 100644 --- a/README.md +++ b/README.md @@ -1449,3 +1449,7 @@ To run this image on a RaspberryPi 3 B+, 4, or newer, use any of the image tags > NOTE: you may need to lower the memory allocation, such as `-e MEMORY=750m` > If experiencing issues such as "sleep: cannot read realtime clock: Operation not permitted", ensure `libseccomp` is up to date on your host. In some cases adding `:Z` flag to the `/data` mount may be needed, [but use cautiously](https://docs.docker.com/storage/bind-mounts/#configure-the-selinux-label). + +## Contributing + +See [Development](DEVELOPMENT.md) and [Building](BUILDING.md). From c7f1d13f9b9cc9da99110546a5a8f4f1a346ffc9 Mon Sep 17 00:00:00 2001 From: itzg Date: Fri, 29 Oct 2021 21:39:37 +0000 Subject: [PATCH 12/14] docs: Auto update markdown TOC --- README.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 5ca3ed57..4b37892e 100644 --- a/README.md +++ b/README.md @@ -131,8 +131,9 @@ By default, the container will download the latest version of the "vanilla" [Min * [Description](#description) * [Enabling Autopause](#enabling-autopause) * [Running on RaspberryPi](#running-on-raspberrypi) + * [Contributing](#contributing) - + From 3713d9c4e8c8f3edb0775db5974ae5816232d8ed Mon Sep 17 00:00:00 2001 From: Geoff Bourne Date: Sun, 31 Oct 2021 09:42:27 -0500 Subject: [PATCH 13/14] Allowed MEMORY to be unset and let JVM calculate from container #742 --- README.md | 4 +++- scripts/start-finalExec | 24 ++++++++++++++++-------- 2 files changed, 19 insertions(+), 9 deletions(-) diff --git a/README.md b/README.md index 4b37892e..bfdb475f 100644 --- a/README.md +++ b/README.md @@ -1288,7 +1288,9 @@ The values of all three are passed directly to the JVM and support format/units -e MEMORY=2G -> NOTE: the settings above only set the Java **heap** limits. Memory resource requests and limits on the overall container should also account for non-heap memory usage. An extra 25% is [a general best practice](https://dzone.com/articles/best-practices-java-memory-arguments-for-container). +> To let the JVM calculate the heap size from the container declared memory limit, unset `MEMORY` with an empty value, such as `-e MEMORY=""`. + +> The settings above only set the Java **heap** limits. Memory resource requests and limits on the overall container should also account for non-heap memory usage. An extra 25% is [a general best practice](https://dzone.com/articles/best-practices-java-memory-arguments-for-container). ### JVM Options diff --git a/scripts/start-finalExec b/scripts/start-finalExec index 60e78d40..1112f104 100755 --- a/scripts/start-finalExec +++ b/scripts/start-finalExec @@ -70,8 +70,8 @@ if [[ ${GUI} = false || ${GUI} = FALSE ]]; then EXTRA_ARGS+=" nogui" fi -# put these prior JVM_OPTS at the end to give any memory settings there higher precedence -log "Setting initial memory to ${INIT_MEMORY:=${MEMORY}} and max to ${MAX_MEMORY:=${MEMORY}}" +: "${INIT_MEMORY:=${MEMORY}}" +: "${MAX_MEMORY:=${MEMORY}}" expandedDOpts= if [ -n "$JVM_DD_OPTS" ]; then @@ -157,7 +157,15 @@ if isTrue "${DEBUG_MEMORY}"; then free -m fi -JVM_OPTS="-Xms${INIT_MEMORY} -Xmx${MAX_MEMORY} ${JVM_OPTS}" +if [[ ${INIT_MEMORY} || ${MAX_MEMORY} ]]; then + log "Setting initial memory to ${INIT_MEMORY:=${MEMORY}} and max to ${MAX_MEMORY:=${MEMORY}}" + if [[ ${INIT_MEMORY} ]]; then + JVM_OPTS="-Xms${INIT_MEMORY} ${JVM_OPTS}" + fi + if [[ ${MAX_MEMORY} ]]; then + JVM_OPTS="-Xmx${MAX_MEMORY} ${JVM_OPTS}" + fi +fi function copyFilesForCurseForge() { # copy player modification files unconditionally since their @@ -197,11 +205,11 @@ elif [[ ${TYPE} == "CURSEFORGE" ]]; then cat > "${FTB_DIR}/settings-local.sh" < Date: Sun, 31 Oct 2021 14:43:07 +0000 Subject: [PATCH 14/14] docs: Auto update markdown TOC --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index bfdb475f..d34486a9 100644 --- a/README.md +++ b/README.md @@ -133,7 +133,7 @@ By default, the container will download the latest version of the "vanilla" [Min * [Running on RaspberryPi](#running-on-raspberrypi) * [Contributing](#contributing) - +