Welcome to Linux Battle Royale! This guide will help you deploy and run the game on your servers using Ansible.
Edit the inventory.ini file and add your target servers:
[linux_servers]
server1 ansible_host=192.168.1.100 ansible_user=root
server2 ansible_host=192.168.1.101 ansible_user=rootReplace 192.168.1.100 with the actual IP addresses of your servers.
Execute the following command to deploy the project:
ansible-playbook -i inventory.ini deploy.ymlThis will:
✅ Install dependencies
✅ Deploy the survival script, leaderboard script, and web app
✅ Start the Flask web server
Once deployed, open a browser and go to:
http://<server-ip>:5000
- Replace
<server-ip>with the IP of any deployed server. - The leaderboard will update dynamically as servers "battle".
Check the survival logs on any server:
cat /var/log/linux_battle.logCheck the leaderboard JSON data:
cat /var/log/leaderboard.jsonIf you want to trigger a manual game round:
bash /usr/local/bin/survival_game.shThis updates the leaderboard immediately.
- 🎨 Customize the leaderboard UI (
web_app/templates/index.html). - 📊 Integrate Grafana/Prometheus for real-time metrics.
- 🔔 Send battle updates to Slack/Discord.
Enjoy the Linux Battle Royale! 🚀🔥