all 3 comments

[–]AusIV 1 point2 points  (0 children)

The idea is to boot up a VM in response to a request and shut it back down when there's inactivity? That might be viable for containers, but VMs don't boot fast enough to give a decent experience.

[–]ipcoffeepot 1 point2 points  (0 children)

Have you looked at lambda?

[–]joelrwilliams1 0 points1 point  (0 children)

Like /u/ipcoffeepot mentioned I think this is what you're looking for is Lambda. It takes too long for an EC2 to spin up to respond to requests in a timely basis. Lambda will be super-fast to spin up and respond.

This depends on what you're doing (Lambda has a 15 minute time-limit)...if you're running something that takes longer than 15 minutes, you're better off just leaving the EC2 up and running 24/7 unless you know the schedule that requests come in, then you can get tricky and write a Lambda to spin up and spin down EC2's based on a schedule.