Skip to content

Instantly share code, notes, and snippets.

@benders
Created April 15, 2024 15:57
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save benders/f7c685d31ac7f7d881008871606c2f8f to your computer and use it in GitHub Desktop.
Save benders/f7c685d31ac7f7d881008871606c2f8f to your computer and use it in GitHub Desktop.
Minecraft Server
version: "3.8"
services:
mc:
image: itzg/minecraft-server
tty: true
stdin_open: true
ports:
- "25565:25565"
environment:
EULA: "TRUE"
DIFFICULTY: "normal"
ONLINE_MODE: "TRUE"
SERVER_NAME: "Johnny Five"
MOTD: "Teddy's Create and More"
ICON: "https://camo.githubusercontent.com/9331e0a8157c2966c533b1ffc34db9d775beb2ddbfc2a99309b588577fbbcd0e/68747470733a2f2f692e696d6775722e636f6d2f535861655057362e706e67"
# OVERRIDE_ICON: "TRUE"
INIT_MEMORY: "1G"
MAX_MEMORY: "4G"
VERSION: "1.20.1"
MOD_PLATFORM: AUTO_CURSEFORGE
CF_API_KEY: "${CF_API_KEY}"
CF_MODPACK_MANIFEST: /manifests/exported-manifest.json
CF_SLUG: name
# Exclude Client Side: CoordinatesDisplay
CF_EXCLUDE_MODS: "646464"
CF_FORCE_SYNCHRONIZE: "TRUE"
volumes:
- ./mc-data:/data
- ./manifests:/manifests:ro
backups:
image: itzg/mc-backup
depends_on:
mc:
condition: service_healthy
environment:
BACKUP_INTERVAL: "1h"
RCON_HOST: mc
# since this service waits for mc to be healthy, no initial delay is needed
INITIAL_DELAY: 0
PAUSE_IF_NO_PLAYERS: "TRUE"
volumes:
- ./mc-data:/data:ro
- ./mc-backups:/backups
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment