Hello, please note i have very little experience with this stuff, and the only way i got a minecraft server up and running was by googling stuff.
I want to secure my droplet with a firewall, the only purpose of the droplet is to be a minecraft server for me and some friends. I know digitalocean allows setting up firewall rules from their control panel,and it has the provision to allow certain IPs through the firewall. Problem is, every player has dynamic IPs, and though I haven’t tried, i don’t think the aforementioned IP rules will allow them through, once their IP changes. Essentially, what I want to do is to reject all connections apart from those that are coming from players. The only way they can connect is through the game client.
Currently the minecraft server is protected only by it’s own whitelist function, but that hasn’t stopped me from nuking the droplet and moving it to a new IP everytime someone I don’t know tries to connect to the minecraft server. I’m pretty sure the last unknown person that tried to connect was using a DO server as a VPN, and tried to connect using an illegitimate minecraft client.
I did see a potential solution online: something about using ufw, a script, and a domain name to update the players IPs in the firewall rules, but wanted some clarification regarding it: would I have to get a website hosted (which is a paid service, as far as I know, and is well out of my budget) for this purpose?
Please let me know if I should relay anymore info about the droplet, or if I have misunderstood anything. Thank you.
Relevant(?) info: server type: droplet, 4 GB memory, 50GB disk
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.
Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in Q&A, subscribe to topics of interest, and get courses and tools that will help you grow as a developer and scale your project or business.
Click below to sign up and get $100 of credit to try our products over 60 days!