Files
NationsGlory_ServeurBuild_Red/docker-compose.yml
y.campiontrebouta@innotexnas.ovh 2589fc7859 feat: Configuration par défaut accepte comptes crack
- Ajoute server.properties.template avec online-mode=false
- docker-compose copie le template au premier démarrage
- Configuration: FLAT, créatif, PvP désactivé, vol autorisé
- Template versionné dans Git (.gitignore mis à jour)
2026-02-04 00:17:47 +01:00

56 lines
1.5 KiB
YAML

services:
nationsglory-modded:
image: itzg/minecraft-server:java7
container_name: mc-nationsglory
restart: unless-stopped
network_mode: "host"
environment:
# IMPORTANT: Ne pas utiliser TYPE, utiliser CUSTOM_SERVER directement
# Cela force le conteneur à utiliser le JAR local au lieu de télécharger
SERVER_PORT: "25565"
RCON_PORT: "25575"
RCON_PASSWORD: "minecraft"
ENABLE_RCON: "true"
SKIP_HEALTH_CHECK: "true"
ACCEPT_EULA: "TRUE"
EULA: "TRUE"
ONLINE_MODE: "FALSE"
DIFFICULTY: "1"
GAMEMODE: "1"
LEVEL_TYPE: "FLAT"
MEMORY: "2G"
INIT_MEMORY: "1G"
JVM_OPTS: "-XX:+UseG1GC -XX:+ParallelRefProcEnabled -XX:MaxGCPauseMillis=200"
# CRITICAL: Désactiver le download automatique
SKIP_SERVER_PROPERTIES: "false"
# Pointer directement au JAR local
CUSTOM_SERVER: "/data/mcpc.jar"
entrypoint: []
command:
- sh
- -c
- |
cd /data
# Copier le template server.properties si inexistant
if [ ! -f server.properties ]; then
cp server.properties.template server.properties 2>/dev/null || true
fi
exec java -Xms1G -Xmx2G -XX:+UseG1GC -XX:+ParallelRefProcEnabled -XX:MaxGCPauseMillis=200 -jar mcpc.jar nogui
volumes:
- .:/data
deploy:
resources:
limits:
memory: 3G
reservations:
memory: 1G
ulimits:
nofile:
soft: 65535
hard: 65535