CS312 Minecraft server automated deployment
We want to create a minecraft server that is basically automatically set up by our Ansible scripts and Docker. Our main goals are:
- Write provisioning for AWS.
- Create configuration and deployment scripts for a Minecraft server.
This will be done using Ansible to set up our AWS resources, then deploy a Minecraft docker image and use the minecraft.service file to set up automatic restarts.
- Ansible
- Docker
- apt
- SSH keys set up in AWS
- ~/.aws/credentials file with current login creds
- Minecraft security group setup in AWS
AWS instance -> Runs Docker -> Dockcer runs Minecraft server -> minecraft systemd service file runs on container
Step 1: Provision Minecraft AWS instance
ansible-playbook provision_aws.yml
Step 2: Install and configure Docker
ansible-playbook -i /tmp/ansible-inventory/hosts configure_docker.yaml
Step 3: Start Minecraft
ansible-playbook -i /tmp/ansible-inventory/hosts run_minecraft.yaml
Step 4: Once the Minecraft server is running, connect to the instance using the public IP provided by the scripts.