Spartan
Spartan

Reputation: 31

How to change min instance of cloud run service configuration automatically at specific time everyday

I have cloud run service running with min instance 0 set. It takes about 20 sec to start the instance and can't make it faster than that.

Also I don't want to keep CPU always ON and set min instance to 1 to avoid higher cost.

I am looking for an option where let's say at specific time in the morning cloud run service config can automatically change to min instance 1 and at night time it changes back to 0.

I think this can be achieveble using creating cloud function to make this change and using cloud scheduler trigger this function. But have little exprience with these services so looking for some template or examples.

just created cloud run hello world service

Upvotes: 2

Views: 637

Answers (0)

Related Questions