{"id":203,"date":"2023-12-24T22:24:45","date_gmt":"2023-12-25T03:24:45","guid":{"rendered":"https:\/\/ziviz.us\/WP\/?p=203"},"modified":"2023-12-24T22:24:45","modified_gmt":"2023-12-25T03:24:45","slug":"running-a-greedycraft-server-with-itzg-docker-minecraft-server","status":"publish","type":"post","link":"https:\/\/www.ziviz.net\/WP\/2023\/12\/24\/running-a-greedycraft-server-with-itzg-docker-minecraft-server\/","title":{"rendered":"Running a GreedyCraft server with itzg\/docker-minecraft-server"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">A quick guide on spinning up a <a href=\"https:\/\/www.curseforge.com\/minecraft\/modpacks\/greedycraft\" data-type=\"link\" data-id=\"https:\/\/www.curseforge.com\/minecraft\/modpacks\/greedycraft\">GreedyCraft<\/a> server in docker with the <a href=\"https:\/\/github.com\/itzg\/docker-minecraft-server\" data-type=\"link\" data-id=\"https:\/\/github.com\/itzg\/docker-minecraft-server\">itzg\/docker-minecraft-server<\/a> container and docker-compose on Linux.<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>Download the <a href=\"https:\/\/www.curseforge.com\/minecraft\/modpacks\/greedycraft\/files\/3350063\" data-type=\"link\" data-id=\"https:\/\/www.curseforge.com\/minecraft\/modpacks\/greedycraft\/files\/3350063\">GreedyCraft server files<\/a> zip file.<\/li>\n\n\n\n<li>Extract the files to a temporary folder. We need to make some changes.\n<ul class=\"wp-block-list\">\n<li>Rename <code>run-linux.sh<\/code> to <code>run.sh<\/code> This is the shell file the docker container will expect, if you do not rename the file, the server will fail to start.<\/li>\n\n\n\n<li>Edit run.sh to include the JVM custom flags. See the <code>README_SERVER_INSALLATION.txt<\/code> for more information about this. For example, assuming a 20GB allocation you could use:<\/li>\n<\/ul>\n<\/li>\n<\/ol>\n\n\n\n<pre class=\"wp-block-code\"><code>java -Xmx20G -Xms20G -Xss4M -Dfile.encoding=GBK -Dsun.rmi.dgc.server.gcInterval=1800000 -XX:+UseG1GC -XX:+UnlockExperimentalVMOptions -XX:G1NewSizePercent=20 -XX:G1ReservePercent=20 -XX:MaxGCPauseMillis=50 -XX:+AlwaysPreTouch -XX:+UseStringDeduplication -Dfml.ignorePatchDiscrepancies=true -Dfml.ignoreInvalidMinecraftCertificates=true -XX:-OmitStackTraceInFastThrow -XX:+OptimizeStringConcat -XX:+UseAdaptiveGCBoundary -XX:G1HeapRegionSize=32M -jar forge-1.12.2-14.23.5.2855.jar nogui<\/code><\/pre>\n\n\n\n<div class=\"wp-block-group\"><div class=\"wp-block-group__inner-container is-layout-constrained wp-block-group-is-layout-constrained\">\n<ul class=\"wp-block-list\">\n<li>Edit the <code>server.properties<\/code> files  per the <code>README_SERVER_INSALLATION.txt<\/code> file. As of this writing, ensure your server.properties has the following lines somewhere in it:<\/li>\n<\/ul>\n<\/div><\/div>\n\n\n\n<pre class=\"wp-block-code\"><code>difficulty=3\nlevel-type=BIOMESOP\nenable-command-block=true\nallow-flight=true<\/code><\/pre>\n\n\n\n<ol class=\"wp-block-list\" start=\"3\">\n<li>Re-zip your files. Name the zip file something like greedy.zip. The file structure in this zip should mirror the one you downloaded.<\/li>\n\n\n\n<li>Copy this zip file wherever you intend your server files to be. For example <code>\/var\/docker\/greedycraft<\/code><\/li>\n\n\n\n<li>Edit your <code>docker-compose.yml<\/code> file and add your configurations. For example, if using 20GB of memory and a data directory of <code>\/var\/docker\/greedycraft<\/code> and a customized server zip file at <code>\/var\/docker\/greedycraft\/greedy.zip<\/code> a <code>docker-compose.yml<\/code> file would look something like (Customize memory and such as needed!):<\/li>\n<\/ol>\n\n\n\n<pre class=\"wp-block-code\"><code>version: \"3\"\nservices:\n  greedycraft:\n    image: itzg\/minecraft-server:java8\n    container_name: greedycraft\n    ports:\n      - \"25565:25565\"\n    restart: unless-stopped\n    environment:\n      EULA: \"TRUE\"\n      SNOOPER_ENABLED: \"FALSE\"\n      MAX_MEMORY: \"20G\"\n      ENABLE_ROLLING_LOGS: \"TRUE\"\n      ENABLE_AUTOPAUSE: \"FALSE\"\n      OVERRIDE_SERVER_PROPERTIES: \"TRUE\"\n      MAX_TICK_TIME: \"-1\"\n      MAX_PLAYERS: \"32\"\n      TYPE: \"CURSEFORGE\"\n      CF_SERVER_MOD: \"greedy.zip\"\n      VERSION: \"1.12.2\"\n    volumes:\n      - \"\/var\/docker\/greedycraft:\/data\"\n    networks:\n      - external\n\nnetworks:\n  external:<\/code><\/pre>\n\n\n\n<ol class=\"wp-block-list\" start=\"6\">\n<li>If all is well, you should be able to start your server by reloading your compose file by running <code>docker-compose up -d<\/code> from the same directory as your <code>docker-compose.yml<\/code> file.<\/li>\n\n\n\n<li>Monitor your server with <code>docker logs greedycraft<\/code> assuming you named the container <code>greedycraft<\/code> like in the example above. If you see repeating logs and <code>docker container ls -a<\/code> shows your container either restarting or with a short uptime, you may have an issue. Stop the container and review the logs to troubleshoot. If you see <code>Stopping aura thread for dim xxx<\/code> however, then you should be good to go! (Assuming no firewall issues and port-forwarding was setup correctly if running across networks, but those are outside the scope of this quick-guide.)<\/li>\n<\/ol>\n","protected":false},"excerpt":{"rendered":"<p>A quick guide on spinning up a GreedyCraft server in docker with the itzg\/docker-minecraft-server container and docker-compose on Linux.<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[13,14,15],"tags":[],"class_list":["post-203","post","type-post","status-publish","format-standard","hentry","category-docker","category-games","category-minecraft"],"_links":{"self":[{"href":"https:\/\/www.ziviz.net\/WP\/wp-json\/wp\/v2\/posts\/203","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.ziviz.net\/WP\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.ziviz.net\/WP\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.ziviz.net\/WP\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.ziviz.net\/WP\/wp-json\/wp\/v2\/comments?post=203"}],"version-history":[{"count":1,"href":"https:\/\/www.ziviz.net\/WP\/wp-json\/wp\/v2\/posts\/203\/revisions"}],"predecessor-version":[{"id":204,"href":"https:\/\/www.ziviz.net\/WP\/wp-json\/wp\/v2\/posts\/203\/revisions\/204"}],"wp:attachment":[{"href":"https:\/\/www.ziviz.net\/WP\/wp-json\/wp\/v2\/media?parent=203"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.ziviz.net\/WP\/wp-json\/wp\/v2\/categories?post=203"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.ziviz.net\/WP\/wp-json\/wp\/v2\/tags?post=203"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}