Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Configuration Files Overwritten #2894

Closed
ByteExceptionM opened this issue Jun 13, 2024 · 5 comments · Fixed by #2895
Closed

Configuration Files Overwritten #2894

ByteExceptionM opened this issue Jun 13, 2024 · 5 comments · Fixed by #2895

Comments

@ByteExceptionM
Copy link

ByteExceptionM commented Jun 13, 2024

Description:
Since my last deployment, configuration files such as paper-global.yml, paper-world-defaults.yml, and spigot.yml are being downloaded and used instead of the ones overridden by my image.

Logs:

  • Previous deployment:
[init] Running as uid=1000 gid=1000 with /data as 'drwxr-xr-x 10 1000 1000 4096 Jun  4 08:59 /data'
[init] Resolving type given PAPER
[mc-image-helper] 05:02:32.263 INFO  : Resolved paper to version 1.20.1 build 196
[init] Removing old mods including:*.jar excluding:
[init] Copying any plugins from /plugins to /data/plugins
[...]
[init] Copying any configs from /config to /data
[mc-image-helper] 08:58:40.128 INFO  : Interpolating /config/commands.yml -> /data/commands.yml
[mc-image-helper] 08:58:40.131 INFO  : Interpolating /config/whitelist.json -> /data/whitelist.json
[mc-image-helper] 08:58:40.131 INFO  : Interpolating /config/bukkit.yml -> /data/bukkit.yml
[mc-image-helper] 08:58:40.132 INFO  : Interpolating /config/server.properties -> /data/server.properties
[mc-image-helper] 08:58:40.132 INFO  : Interpolating /config/config/paper-world-defaults.yml -> /data/config/paper-world-defaults.yml
[mc-image-helper] 08:58:40.133 INFO  : Interpolating /config/config/paper-global.yml -> /data/config/paper-global.yml
[mc-image-helper] 08:58:40.134 INFO  : Interpolating /config/config/worlds/fw_end/paper-world.yml -> /data/config/worlds/fw_end/paper-world.yml
[mc-image-helper] 08:58:40.135 INFO  : Interpolating /config/config/worlds/fw_normal/paper-world.yml -> /data/config/worlds/fw_normal/paper-world.yml
[mc-image-helper] 08:58:40.135 INFO  : Interpolating /config/config/worlds/fw_nether/paper-world.yml -> /data/config/worlds/fw_nether/paper-world.yml
[mc-image-helper] 08:58:40.136 INFO  : Interpolating /config/spigot.yml -> /data/spigot.yml
[mc-image-helper] 08:58:41.022 INFO  : Created/updated 2 properties in /data/server.properties
  • Latest deployment:
[init] Running as uid=1000 gid=1000 with /data as 'drwxr-xr-x 6 1000 1000 4096 Jun 11 07:13 /data'
[init] Resolving type given PAPER
[mc-image-helper] 07:13:03.020 INFO  : Resolved paper to version 1.20.1 build 196
[mc-image-helper] 07:13:03.535 INFO  : Downloaded /data/paper-1.20.1-196.jar
[mc-image-helper] 07:13:04.808 INFO  : Downloaded config/paper-global.yml
[mc-image-helper] 07:13:04.947 INFO  : Downloaded config/paper-world-defaults.yml
[mc-image-helper] 07:13:05.102 INFO  : Downloaded config/spigot.yml
[init] Removing old mods including:*.jar excluding:
[init] Copying any plugins from /plugins to /data/plugins
[...]
[init] Copying any configs from /config to /data
[mc-image-helper] 07:13:07.134 INFO  : Interpolating /config/commands.yml -> /data/commands.yml
[mc-image-helper] 07:13:07.137 INFO  : Interpolating /config/whitelist.json -> /data/whitelist.json
[mc-image-helper] 07:13:07.138 INFO  : Interpolating /config/bukkit.yml -> /data/bukkit.yml
[mc-image-helper] 07:13:07.138 INFO  : Interpolating /config/server.properties -> /data/server.properties
[mc-image-helper] 07:13:07.139 INFO  : Interpolating /config/config/worlds/fw_end/paper-world.yml -> /data/config/worlds/fw_end/paper-world.yml
[mc-image-helper] 07:13:07.140 INFO  : Interpolating /config/config/worlds/fw_normal/paper-world.yml -> /data/config/worlds/fw_normal/paper-world.yml
[mc-image-helper] 07:13:07.140 INFO  : Interpolating /config/config/worlds/fw_nether/paper-world.yml -> /data/config/worlds/fw_nether/paper-world.yml
[mc-image-helper] 07:13:07.140 INFO  : Interpolating /config/spigot.yml -> /data/spigot.yml
[mc-image-helper] 07:13:08.045 INFO  : Created/updated 2 properties in /data/server.properties

Related Release:
This might be related to the recent release: v1.38.16.

Steps to Reproduce:

  1. Deploy itzg/minecraft-server:java21
  2. Observe that the custom configuration files are not used.

Expected Behavior:
The custom configuration files provided in my image should be used instead of downloading the default ones.

Actual Behavior:
Default configuration files are downloaded and used, ignoring the custom files in the image.

Additional Context:
I have already checked my image and there are no errors in it. According to the logs, the configs are interpolated - but the downloaded files are used, as the active ones are definitely not my custom configs.

@itzg itzg transferred this issue from itzg/mc-image-helper Jun 13, 2024
@itzg
Copy link
Owner

itzg commented Jun 13, 2024

Please provide your container configuration since there must be an interaction with another feature I didn’t account for.

FYI moved this issue since it was directly caused by helper change.

@ByteExceptionM
Copy link
Author

Please provide your container configuration since there must be an interaction with another feature I didn’t account for.

FYI moved this issue since it was directly caused by helper change.

Sure!

ARG ITZG_TAG
FROM itzg/minecraft-server:${ITZG_TAG}

# https://spark.lucko.me/docs/misc/Using-async-profiler
RUN apk add --no-cache libstdc++
#RUN apt-get install libstdc++6

ENV TZ=Europe/Berlin

ENV EULA=TRUE

ENV TYPE=PAPER

ENV MEMORY=${MEMORY:-512M}
ENV USE_AIKAR_FLAGS=true

ENV STOP_DURATION=600

ENV REMOVE_OLD_MODS=TRUE
ENV REMOVE_OLD_MODS_INCLUDE=*.jar
ENV REMOVE_OLD_MODS_DEPTH=1

ENV COPY_CONFIG_DEST=/data

ENV REPLACE_ENV_VARIABLES=TRUE
ENV ENV_VARIABLE_PREFIX=CFG_

COPY config /config
COPY plugins /plugins

@itzg
Copy link
Owner

itzg commented Jun 13, 2024

Ah yes, it's probably not interacting well with the config mount mechanism. I'll investigate a better point in startup to do that.

@itzg
Copy link
Owner

itzg commented Jun 13, 2024

For now the previous behavior will be restored after this image is pushed

https://github.com/itzg/docker-minecraft-server/actions/runs/9499890115

@ByteExceptionM
Copy link
Author

Okay - great. Thanks for your quick help!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants