Dom. Dic 22nd, 2024

After a time working with Chef Server and taking advantage of a change of job where you had to start automating deployments and configuration management from scratch, I decided to work with Ansible by the simplest (no central servers), clean (Bye bye Ruby gems) and direct architecture that presents and its proximity to knowledge systems administrator (ssh, python, yaml …)

ansible-logo

And recently I wanted to use this knowledge to make a small personal project that gathered one of my hobbies, video games, with this newly acquired knowledge of Ansible.

jugar minecraftSo consequently I developed a playbook (available in https://github.com/juanviz/ansible) that installs a Minecraft game server, third best-selling of all history today and currently selling 10,000 copies daily, in a public EC2 instance and a Raspberry Pi 1 model B in local (although nothing prevents it accessible via the Internet as well as the EC2 instance) so that any user can play Minecraft .

Videogame architecture is client / server and JAVA code in both cases.

In the case of EC2 instance it has been able to use the official version of the server, https://mcversions.net/.

 

30f249dIn the case of the Raspberry PI due to the  hardware limitations I used a modified version, Spigot, just that I have compiled according to the instructions on this page and the settings included in the playbook (plugin NoSpawnChunks) included works swimmingly ( with a limit of 5 simultaneous players) using 364 MB of RAM.

maxresdefaultIn the readme.md you have the basic instructions to execute the playbook, but we really only have to change the inventory to set the ip / url addresses of your EC2 instance and your Raspsberry Pi.

Recommended to add the following configuration ssh (edit $ HOME / .ssh / config) on the machine where the workstation for ease of use (explained in the readme) is executed:

host urldetuinstanciaec2
user ubuntu
IdentityFile ~ / .ssh / tukeypairprivado.pem

The playbook installed java 1.8 and Oracle scripts start / stop.

Currently the playbook only provides OS Ubuntu / Debian but will be updated for other operating systems.

To verify that everything works correctly you need register in minecraft.net and buy your license (19.95 euros) and follow the simple instructions explained in this video.

The whole process of implementing the playbook, and boot server connection using the Minecraft client is explained in the following video


Enjoy the game!

Documentation consulted:

minecraft.net
ansible.com
raspberry Pi
https: //www.spigotmc.org/wiki/spigot-installation/#linux

http: //minecraft.gamepedia.com/Pi_Edition

https: //www.raspberrypi.org/learning/getting-started-with-minecraft-pi/worksheet/

https: //pimylifeup.com/raspberry-pi-minecraft-server/

EC2
https: //qwiklabs.com/focuses/2628 locale = en

0 comentario en “Deploy and provision of a Minecraft Server in RPi andAWS with Ansible, Terraform and Jenkins (Part I)”

Deja una respuesta

Tu dirección de correo electrónico no será publicada. Los campos obligatorios están marcados con *