Yes, 5-10 minutes is usually the expectation.
When you terminate your only instance in the fleet, but the “desired” scaling size is 1, EC2 Autoscaling will allocate a new instance to the fleet. This will take some time depending on the fleet type (spot or on demand), instance type and region. Once the instance is allocated, it’ll take some time to start up the instance with your build loaded, and once that’s done, it’ll need to start the game server process.
Are you terminating your instance to kill your game session during development? If so, there are a few tricks to do that without terminating the instance:
- SSH to the fleet instance using getInstanceAccess (get-instance-access — AWS CLI 1.19.85 Command Reference), do a “ps -ef” on the instance to look for your game server’s launch path, find the PID and kill it.
- Spin up multiple processes, each listening to a different port
- Create a timer in the game server process, and automatically call
ProcessEnding() and exit the process when the timer expires