version: '3' services: minecraft: image: itzg/minecraft-server restart: "unless-stopped" stdin_open: true volumes: - ./mc/data:/data - ./mc/mods:/mods:ro - ./mc/icon.png:/icon.png - ./mc/whitelist.json:/whitelist.json:ro #- ./mc/mc2discord.toml:/data/config/mc2discord.toml depends_on: - lazytainer network_mode: service:lazytainer labels: - "lazytainer.group=minecraft" environment: EULA: "TRUE" TYPE: FORGE VERSION: "1.20.1" FORGE_VERSION: "47.2.32" INIT_MEMORY: 128M MAX_MEMORY: 25G TZ: "Europe/Berne" ICON: "/icon.png" SNOOPER_ENABLED: "FALSE" #SEED: "" OVERRIDE_SERVER_PROPERTIES: "TRUE" MAX_TICK_TIME: "-1" DIFFICULTY: "normal" MODE: "survival" # survival, creative, adventure, spectator MOTD: "Bachelor's Minecraft Server" ENABLE_WHITELIST: "TRUE" WHITELIST_FILE: "/whitelist.json" OVERRIDE_WHITELIST: "TRUE" lazytainer: image: ghcr.io/vmorganp/lazytainer:master environment: VERBOSE: false ports: - 25565:25565 volumes: - /var/run/docker.sock:/var/run/docker.sock:ro labels: - lazytainer.group.minecraft.sleepMethod=stop - lazytainer.group.minecraft.ports=25565 - lazytainer.group.minecraft.minPacketThreshold=2 # Start after two incoming packets - lazytainer.group.minecraft.inactiveTimeout=300 restart: unless-stopped network_mode: bridge