docker-compose.yml 6.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144
  1. version: '3'
  2. # docker-compose up -d
  3. services:
  4. minecraft-server:
  5. ports:
  6. - "11611:25565"
  7. environment:
  8. EULA: "true"
  9. VERSION: "1.16.1"
  10. # on Type Forge, by default the container will run the RECOMMENDED version of Forge server
  11. #TYPE: FORGE
  12. # ...but you can also choose to run a specific version with:
  13. #FORGEVERSION: 31.2.36
  14. # By default the server configuration will be created and set based on the following environment variables,
  15. # but only the first time the server is started.
  16. # If the server.properties file already exists, the values in them will not be changed.
  17. # If you would like to override the server configuration each time the container starts up,
  18. # you can set the OVERRIDE_SERVER_PROPERTIES environment variable like:
  19. # false, to set level_type to biomesoplenty
  20. OVERRIDE_SERVER_PROPERTIES: "false"
  21. SERVER_NAME: MC-1.16.1
  22. SERVER_PORT: 25565
  23. DIFFICULTY: 0
  24. #WHITELIST: user1,user2
  25. OPS: Reaver1202,SuminoSempai,SYYRN
  26. #ICON: http://..../some/image.png
  27. LEVEL: "A brave new world!"
  28. # RCRON
  29. #ENABLE_RCON: "true"
  30. #RCON_PASSWORD: testing
  31. #RCON_PORT: 25575
  32. # By default the query port will be 25565 (UDP)
  33. #ENABLE_QUERY: "true"
  34. MAX_PLAYERS: 10
  35. # maximum possible size in blocks, expressed as a radius, that the world border can obtain
  36. #MAX_WORLD_SIZE: 10000
  37. ALLOW_NETHER: "true"
  38. ANNOUNCE_PLAYER_ACHIEVEMENTS: "true"
  39. ENABLE_COMMAND_BLOCK: "true"
  40. # Force players to join in the default game mode.
  41. # "false" - Players will join in the gamemode they left in.
  42. # "true" - Players will always join in the default gamemode.
  43. FORCE_GAMEMODE: "false"
  44. # Defines whether structures (such as villages) will be generated.
  45. # "false" - Structures will not be generated in new chunks.
  46. # "true" - Structures will be generated in new chunks.
  47. GENERATE_STRUCTURES: "true"
  48. # If set to "true", players will be set to spectator mode if they die.
  49. HARDCORE: "false"
  50. # If set to "false", the server will not send data to snoop.minecraft.net server.
  51. SNOOPER_ENABLED: "false"
  52. MAX_BUILD_HEIGHT: 256
  53. # The maximum number of milliseconds a single tick may take before the server watchdog stops the server with the message,
  54. # A single server tick took 60.00 seconds (should be max 0.05); Considering it to be crashed, server will forcibly shutdown.
  55. # Once this criteria is met, it calls System.exit(1). Setting this to -1 will disable watchdog entirely
  56. MAX_TICK_TIME: 60000
  57. # Determines if animals will be able to spawn.
  58. SPAWN_ANIMALS: "true"
  59. # Determines if monsters will be spawned.
  60. SPAWN_MONSTERS: "true"
  61. # Determines if villagers will be spawned.
  62. SPAWN_NPCS: "true"
  63. # Sets the area that non-ops can not edit (0 to disable)
  64. SPAWN_PROTECTION: 0
  65. # Sets the amount of world data the server sends the client, measured in chunks
  66. # in each direction of the player (radius, not diameter). It determines the server-side viewing distance.
  67. VIEW_DISTANCE: 10
  68. #SEED: 2101715061381480750
  69. # By default, Minecraft servers are configured to run in Survival mode.
  70. # creative, survival, adventure, spectator
  71. MODE: survival
  72. # message of the day, shown below each server entry in the UI
  73. MOTD: Have a nice day! Tobi
  74. # By default, servers are created with player-vs-player (PVP) mode enabled.
  75. PVP: "false"
  76. # DEFAULT, FLAT, LARGEBIOMES, AMPLIFIED, CUSTOMIZED, BUFFET
  77. LEVEL_TYPE: DEFAULT
  78. #LEVEL_TYPE: biomesoplenty
  79. #### MODS
  80. # Like the WORLD option above, you can specify the URL of a "mod pack" to download and install into mods for Forge or plugins
  81. # for Bukkit/Spigot. To use this option pass the environment variable MODPACK, such as the example below.
  82. # NOTE: The referenced URL must be a zip file with one or more jar files at the top level of the zip archive. Make sure the
  83. # jars are compatible with the particular TYPE of server you are running.
  84. #MODPACK: http://www.example.com/mods/modpack.zip
  85. # When the option above is specified (MODPACK) you can also instruct script to delete old mods/plugins prior to installing
  86. # new ones. This behaviour is desirable in case you want to upgrade mods/plugins from downloaded zip file.
  87. #REMOVE_OLD_MODS: true
  88. # You may also download individual mods using the MODS environment variable and supplying the URL to the jar files.
  89. # Multiple mods/plugins should be comma separated.
  90. #MODS: https://www.example.com/mods/mod1.jar,https://www.example.com/mods/mod2.jar
  91. # WARNING: All content of the mods or plugins directory will be deleted before unpacking new content from the MODPACK or MODS.
  92. # Allows users to use flight on your server while in Survival mode, if they have a mod that provides flight installed.
  93. ALLOW_FLIGHT: "true"
  94. # Memory Limit
  95. MEMORY: 4G
  96. INIT_MEMORY: 4G
  97. MAX_MEMORY: 4G
  98. # JVM Options
  99. # General JVM options can be passed to the Minecraft Server invocation by passing a JVM_OPTS environment variable.
  100. # Options like -X that need to proceed general JVM options can be passed via a JVM_XX_OPTS environment variable.
  101. # For some cases, if e.g. after removing mods, it could be necessary to startup minecraft with an additional
  102. # -D parameter like -Dfml.queryResult=confirm. To address this you can use the environment variable JVM_DD_OPTS,
  103. # which builds the params from a given list of values separated by space, but without the -D prefix. To make things
  104. # running under systems (e.g. Plesk), which doesn't allow = inside values, a : (colon) could be used instead.
  105. # The upper example would look like this: JVM_DD_OPTS=fml.queryResult:confirm, and will be converted to -Dfml.queryResult=confirm.
  106. image: itzg/minecraft-server:latest
  107. volumes:
  108. - "/home/tobi/docker-minecraft_16-1/data:/data"
  109. container_name: mc1161
  110. tty: true
  111. stdin_open: true