I'm trying to find a way to design a game server architecture for a real time mobile game. The design should be cost effective but still to some extend scaleable (later on).
Mobile client flow:
Connects to a distributor server which was given by DNS LB and gets grouped with x players. If y players are reached, the distributor server needs to contact a control server, which starts or uses a already running game server. The control server sends back the ip and port to the distributor server which then sends it to the grouped players. The players then connect to the given game server. After the game the players will be send together to a new or same distributor server.
I wonder how the real server (VMs) for the game servers can be managed in a dynamic matter. I have looked at AWS EC2 instances, but if we have 500 players with 6 players per group that play 6 hours per day, we would need ~84 EC2 t3.small (2 vCPU, 2GiB RAM) instances running. This will cost ~1,160.00 USD monthly. With this price it would be favorable to have real VMs and not dynamic cloud instances I guess?
Explanation of the components
Mobile clients will connect to these to get grouped with other players. It's like a lobby where players will sit until X players are reached or eg. a countdown ran out.
Need to take care of started server (VMs) and handle game server start requests from the distributors.
Is an authoritive like server client with physics etc. One game server (software) for X players in a group. Players will connect to these from the distributor after the lobby "phase".
How can this be dynamic scaleable/cost effective and is this a useable architecture? I see one problem with the control server because it must take care of N game server vms and N distributors. But if we scale the control server, then every control server needs to know the same as every other.
(If anything is missing or can be improved, please let me know. English is not my native language so it's a bit challenging to express my goal in such a complicated topic like this)