{"id":27160388,"url":"https://github.com/madness-gaming-network/madguard","last_synced_at":"2026-04-15T06:32:48.518Z","repository":{"id":223063645,"uuid":"714845642","full_name":"Madness-Gaming-Network/MadGuard","owner":"Madness-Gaming-Network","description":"A Discord bot that helps manage self-service Wireguard networks for small to large groups of gamers.","archived":false,"fork":false,"pushed_at":"2024-02-25T01:11:32.000Z","size":6081,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-03-21T07:45:11.667Z","etag":null,"topics":["bot","discord","gaming","lan","networking","p2p","wireguard"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Madness-Gaming-Network.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-11-06T00:41:32.000Z","updated_at":"2024-02-25T01:13:43.000Z","dependencies_parsed_at":"2024-06-21T03:58:55.618Z","dependency_job_id":"62e7e41a-d4d3-4af0-9713-2d1c9b7f6166","html_url":"https://github.com/Madness-Gaming-Network/MadGuard","commit_stats":null,"previous_names":["madness-gaming-network/discord_bot","madness-gaming-network/madguard"],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Madness-Gaming-Network%2FMadGuard","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Madness-Gaming-Network%2FMadGuard/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Madness-Gaming-Network%2FMadGuard/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Madness-Gaming-Network%2FMadGuard/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Madness-Gaming-Network","download_url":"https://codeload.github.com/Madness-Gaming-Network/MadGuard/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247947821,"owners_count":21023058,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["bot","discord","gaming","lan","networking","p2p","wireguard"],"created_at":"2025-04-08T23:45:08.468Z","updated_at":"2026-04-15T06:32:43.480Z","avatar_url":"https://github.com/Madness-Gaming-Network.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# MadGuard\n\n\u003cimg src=\"./pb_public/images/MadGuard.png\" width=\"512\" height=\"512\" /\u003e\n\nMadness + WireGuard\n\n## TODO\n\n- Learn Gin again: https://github.com/gin-gonic/gin/blob/master/docs/doc.md\n- Figure out how to automate release, basic process is like: (change numbers based on semantic versioning)\n  ```\n  git tag -a v0.1.0 -m \"First release\"\n  git push origin v0.1.0\n  ```\n  - It would be helpful to automate the version incrementing part, but for now it will be manual\n- We'll also need to figure out how to automate getting the correct binaries to the VPS\n  - We could just do something like `wget https://github.com/Madness-Gaming-Network/MadGuard/releases/download/v0.1.0/MadGuard_Linux_x86_64.tar.gz`\n  - Auth is generally a pain on remote servers, so we'll have to research or something\n  - For now we can just manually `scp` the tarball/binary over\n- Set up basic Caddy config: https://github.com/caddyserver/caddy\n- Figure out basic unit/integration test setup\n- Document systemd setup for auto restarts (instead of something like pm2 for Node)\n  - https://www.linux.org/docs/man1/systemd-run.html\n  - Or maybe use https://github.com/cloudflare/tableflip ?\n- Figure out how to \"publish\" or distribute bot?\n  - https://discord.com/developers/docs/getting-started\n  - https://discord.com/developers/applications\n\n## Decisions\n\n- Golang, because:\n  - WireGuard, Caddy, Pocketbase, and more are built with it\n  - Way more documentation, resources, and examples\n  - Simpler syntax\n    - Supposedly better for ChatGPT (GitHub Copilot) prompting too?\n- Simplest possible infrastructure\n  - Focus on getting MVP working first, then automating\n  - Minimize dependencies\n  - No Kubernetes until absolutely neccessary, regular VPS deploys are fine\n  - When in doubt, \"shift left\", \"reduce scope when possible\", and \"the best code is no code at all\"\n\n## Potential Commands\n\n- Create/read/update/delete (CRUD) WireGuard network\n  - Only for trusted users, otherwise they have to request networksk manually (automating too much early on could lead to easier abuse)\n  - Inputs: Network name, users, desired expiration, ???\n- CRUD user from existing WireGuard network\n  - Inputs: Email, IP range, games, ???\n- CRUD server/session in emulator\n  - Inputs: ???\n\n\n### Other Feature Ideas / Questions\n\n- Pull Discord roles and use those for permissions\n  - Mirror some anonymous Discord user data in Pocketbase, like Discord ID and permissions\n- Host on same VPS as WireGuard server?\n  - Probably not, maybe separate server?\n- Discord donation/sponsorship/boosting gives more features?\n  - https://discord.com/developers/docs/monetization/overview\n  - Longer network expiration?\n  - More players\n  - Etc?\n- Consider serverless?\n  - Only as last resort to minimize cost\n\n\n## Useful Commands\n\n```\n# Download the release (requires public repo, as mentioned in TODO section)\nwget https://github.com/Madness-Gaming-Network/MadGuard/releases/download/v0.1.0/discord_bot_Linux_x86_64.tar.gz\n\n# Extract `discord_bot` executable from GitHub release tarball\ntar -xvzf discord_bot_Linux_x86_64.tar.gz\n\n# Set up SSH keys on server (will prompt for root user password on server)\nssh-copy-id -i ~/.ssh/madness-server-ssh-key.pub root@142.171.162.80\n\n# SSH into server with specific SSH key (will ask for SSH key password)\nssh -i ~/.ssh/madness-server-ssh-key root@142.171.162.80\n\n# Copy over `discord_bot` executable\nscp -i ~/.ssh/madness-server-ssh-key root@142.171.162.80:/root/discord_bot ./discord_bot\n\n# Run it (on server)\n./discord_bot\n```\n\n# Contributing\n\nWe don't have good guidelines for this yet; please reach out on Discord for info.\n\n# Disclaimers\n\n[WireGuard®](https://www.wireguard.com/) is a registered trademark of Jason A. Donenfeld.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmadness-gaming-network%2Fmadguard","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmadness-gaming-network%2Fmadguard","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmadness-gaming-network%2Fmadguard/lists"}