#Packet limiting, server side validation, mass hosting
28 messages · Page 1 of 1 (latest)
Another thing I'd like to know, would hardcoding a servers DDNS ip be fine?
I'm assuming it would be much better than a public IP of an AWS server?
If you're using elb you're supposed to use it's domain name because it's IP can change.
Whatever is your first point of contact definitely use a domain name so you don't have to update your game if the associated IP(s) change.
A have a two step process where I have a web service that keeps track of my servers in each region and when a client asks it to create a new room it gives it the domain name for one of the servers. Then when clients ask to join that same room they connect to the same server.
So setup a DDNS for my server, hardcode that into the mirror ip join, and it should be fine?
No-IP, DynDNS, and DuckDNS
Are ones I looked at
Why would your server have a DDNS? Isn't DDNS usually used for hosts that change IPs?
Why?
I mean I know I can setup security flags, firewall, cloudfare etc. I just assumed hard coding the public ip was unsafe, I don't know
Security Risks: Hard-coding IP addresses can be a security risk, as it exposes the actual IP address of your server to potential attackers. It's generally a best practice to keep server IP addresses hidden from public exposure
Is that because you think the IP might change or it that because you think having the IP in your game would make it easier to DDOS your game?
1st one mainly, as i know I could setup a Load Balancer/DDNS, and also the second could occur right?
Well yeah if you want load balancing and multiple servers you can't hardcore the ip or domain name of any one server.
And you need to direct all clients that want to join the same room to the same server
So I would have an EC2 setup with a dynamic DNS.
The clients join to this mass server.
This server then checks what other EC2 instances are free to join for a match and connects the client to it?
The clients join to this mass server.
I actually have multiple ec2 servers behind a load balancer for that. It's much easier to scale in that way than game servers because unlike game servers they're stateless (backed by a database and their IPs from one request to the next don't matter to the clients).
The dynamic DNS part is assumed by the aws load balancer, for which you're supposed to point to using a CNAME
But then my clients get directed to available game servers depending and their region and the load on each servers (making sure all clients that want to join a same room get the same server).
I don't use ec2 for the game servers themselves because I'd be too worried about the bandwidth bill
Yea I'm a bit worried about that too to be honest with you.
I suppose I'll take a look into making multi ec2 servers for a load balancer and see if dynamodb or some other way would be a good way to check servers / ips etc. Thank you.
You know there are "free" matchmaking services like the one epic offers right? You're making a conscious choice to do it yourself and you have the resources to do so? I'm not saying it can't be done just want to make sure you know what you're getting yourself into.