mirror of
https://github.com/itzg/docker-minecraft-server
synced 2024-12-14 06:12:27 +00:00
4587b32480
Co-authored-by: christopher blodgett <christopher.blodgett@gmail.com>
24 lines
668 B
YAML
24 lines
668 B
YAML
version: '3'
|
|
|
|
services:
|
|
minecraft:
|
|
image: ${IMAGE_TO_TEST:-itzg/minecraft-server}
|
|
ports:
|
|
- "25565:25565"
|
|
volumes:
|
|
- "mc:/data"
|
|
environment:
|
|
EULA: "TRUE"
|
|
# YAML Heredoc, be sure to use '|-' this will remove the first newline and final new line.
|
|
# This is versus '|' that will leaving with two empty strings at top and bottom.
|
|
RCON_CMDS_STARTUP: |-
|
|
/gamerule doFireTick false
|
|
/team add New
|
|
/team add Old
|
|
RCON_CMDS_ON_CONNECT: |-
|
|
/team join New @a[team=]
|
|
/give @a[team=New] diamond_block
|
|
/team join Old @a[team=New]
|
|
restart: unless-stopped
|
|
volumes:
|
|
mc: {}
|