Difference between revisions of "How To Host A DIY Minecraft Server At Home With Docker"

From Trade Britannica
Jump to: navigation, search
m
m
 
Line 1: Line 1:
<p> My oldest child discovered Minecraft recently. My son, on the other hand is playing Bedrock Edition on an iPad and a game console. He prefers Java Edition on an older computer. (And he can launch it via the terminal! ) To play with each other I thought about running a Dockerized Minecraft server on my home server and it was more straightforward than I anticipated.</p><br /><br /><p> Operating a dedicated server</p><br /><br /><p> The official server distribution is one Java jar, which means it ought to be pretty simple to run. Before trying it, though, I searched for Docker images, and found a good one: itzg/minecraft-server.</p><br /><br /><p> You can either open the container with the docker run command or daemonize it. However, I've kept it simple by setting docker compose in a byobu session.</p><br /><br /><p> Here's my current docker.yml file.</p><br /><br /><p> There are many possible configuration options, however I'd like to highlight two things above:</p><br /><br /><p> Game's persistent data are written to a volume that is mounted on the host. This lets us easily access the files. The "WORLD" option is useful for importing the save file that was originally created on a different computer.</p><br /><br /><p> Connecting to the Server</p><br /><br /><p> The server will be able to accept connections within a few seconds. However, my clients aren't able to see it. Minecraft will remain on the "Scanning for games on your local network" screen forever. [https://writeablog.net/tailbrain1/eve-evolution-how-do-you-create-a-sandbox I'm bonnie and you are] You can still "Add Server" to manually add it, and voila!</p><br /><br /><p> Web Map</p><br /><br /><p> My Minecraft knowledge is about a decade old. But, I'm aware that third-party tools can produce an online view of the Minecraft world, similar to the one in Google Maps. After doing some research it appears that Minecraft Overviewer is the prominent one in the present.</p><br /><br /><p> As I mentioned before, the installation appears fairly straightforward however, I came across a Docker image that's even easier. This is a single-shot process (not an ongoing service) We'll make use of docker run:</p><br /><br /><p> Leaflet will create a web map that has read-only access to game data from the other container and another volume to write it to. This directory can be symlinked to a web-served directory on the host, for example /var/www/public_html, for ease of access from any web browser.</p><br /><br /><p> Although it takes only just a few minutes to complete but the results are impressive.</p><br /><br /><p> Makefile</p><br /><br /><p> Finally, as is my habit, I threw a few shortcuts in a Makefile to make them easy to access:</p><br /><br /><p> Motives to build Dockerized Minecraft Server</p><br /><br /><p> A DIY dedicated server is probably unnecessary for most people. If you're wanting to play locally using multiplayer and one of your computers is powerful enough you can click "Open to LAN" directly from the game. If you're looking to play with a larger group of folks outside your household You're better off with a paid hosted server. This could be the official "Realms" or any of several third-party alternatives.</p>
+
<p> My oldest son recently jumped into Minecraft. While a lot of his friends play Bedrock Edition on an iPad or game console, my son plays the old-fashioned Java Edition on an old computer. (And he launches it from the terminal! ) To play with each other I thought about running a Dockerized Minecraft server on my home server and it was simpler than I had expected.</p><br /><br /><p> A dedicated server is running</p><br /><br /><p> The official server distribution includes a single Javajar. [https://userscloud.com/my3u7u80szhe best minecraft servers] It should be simple to use. Before trying it, though, I searched for Docker images, and found a good one: itzg/minecraft-server.</p><br /><br /><p> You can either open the container using a docker run command or daemonize it. I prefer to keep it simple and set docker compose within my byobu session.</p><br /><br /><p> Here's my current docker.yml file.</p><br /><br /><p> There are a variety of configuration options however I'd like to focus on two:</p><br /><br /><p> - Game's persistent data are written to a volume that is mounted on the host. This lets us quickly access the files. The "WORLD" option allows you to import a save that was created on a different computer.</p><br /><br /><p> Connecting to the Server</p><br /><br /><p> The server will accept connections within a couple of seconds. However my clients aren't in a position to see it. Minecraft will remain on the "Scanning games on your local network" screen for as long as. Whatever the case you want to do, simply click "Add Server" to add it manually, and voila!</p><br /><br /><p> Web Map</p><br /><br /><p> Most of my Minecraft knowledge is 10 years old. However, I'm aware of third-party tools can produce an online representation of a Minecraft world, similar to the one in Google Maps. After searching around, it seems like Minecraft Overviewer is the prominent one in the present.</p><br /><br /><p> Although the installation process is easy, I discovered an Docker file that was simpler. This one's a one-shot process (not an ongoing service) We'll make use of docker run:</p><br /><br /><p> Leaflet will create a web map with read-only access to game data from the other container and another volume to write it to. This directory can be symlinked to a web-served directory on the host, such as the /var/www/public_html directory, which allows easy access from any web browser.</p><br /><br /><p> Even though it only takes just a few minutes to complete but the results are impressive.</p><br /><br /><p> Makefile</p><br /><br /><p> Lastly, as is my custom I added a few shortcuts in the Makefile to make them easy to access:</p><br /><br /><p> Reasons You Might Want to build a Dockerized Minecraft Server</p><br /><br /><p> The majority of people don't require dedicated servers. If you're just looking to play local multiplayer and one of your computers is sufficiently powerful you can click "Open to the LAN" directly from the game. If you're looking to play with a large group of players outside of your household it's best to go with a paid hosted server. It could be the official "Realms" or one of the many third-party alternatives.</p>

Latest revision as of 11:24, 19 July 2022

My oldest son recently jumped into Minecraft. While a lot of his friends play Bedrock Edition on an iPad or game console, my son plays the old-fashioned Java Edition on an old computer. (And he launches it from the terminal! ) To play with each other I thought about running a Dockerized Minecraft server on my home server and it was simpler than I had expected.



A dedicated server is running



The official server distribution includes a single Javajar. best minecraft servers It should be simple to use. Before trying it, though, I searched for Docker images, and found a good one: itzg/minecraft-server.



You can either open the container using a docker run command or daemonize it. I prefer to keep it simple and set docker compose within my byobu session.



Here's my current docker.yml file.



There are a variety of configuration options however I'd like to focus on two:



- Game's persistent data are written to a volume that is mounted on the host. This lets us quickly access the files. The "WORLD" option allows you to import a save that was created on a different computer.



Connecting to the Server



The server will accept connections within a couple of seconds. However my clients aren't in a position to see it. Minecraft will remain on the "Scanning games on your local network" screen for as long as. Whatever the case you want to do, simply click "Add Server" to add it manually, and voila!



Web Map



Most of my Minecraft knowledge is 10 years old. However, I'm aware of third-party tools can produce an online representation of a Minecraft world, similar to the one in Google Maps. After searching around, it seems like Minecraft Overviewer is the prominent one in the present.



Although the installation process is easy, I discovered an Docker file that was simpler. This one's a one-shot process (not an ongoing service) We'll make use of docker run:



Leaflet will create a web map with read-only access to game data from the other container and another volume to write it to. This directory can be symlinked to a web-served directory on the host, such as the /var/www/public_html directory, which allows easy access from any web browser.



Even though it only takes just a few minutes to complete but the results are impressive.



Makefile



Lastly, as is my custom I added a few shortcuts in the Makefile to make them easy to access:



Reasons You Might Want to build a Dockerized Minecraft Server



The majority of people don't require dedicated servers. If you're just looking to play local multiplayer and one of your computers is sufficiently powerful you can click "Open to the LAN" directly from the game. If you're looking to play with a large group of players outside of your household it's best to go with a paid hosted server. It could be the official "Realms" or one of the many third-party alternatives.