Skip to content

Scale to zero

Scale to zero is a setting that lets a web deployment on Ownkube Compute drop to zero running replicas when it stops receiving traffic, then wake again on the next request. Because active CPU and working-set memory only bill while a replica exists, an app at zero replicas costs nothing while it sleeps.

To turn it on, switch on Scale to zero in a web deployment’s Settings tab and choose how long the app can go without requests before it sleeps (1 to 60 minutes, 5 by default). Ownkube then removes all replicas once that idle window passes, and starts a replica again as soon as a new request arrives. That first request pays a brief cold start while the replica wakes; every request after it is served normally.

Every web app, database and cache on Ownkube Compute can sleep. A web app needs a public hostname, since the incoming request is what wakes it, and a database or cache wakes on its next connection. See Sleep and wake. It doesn’t apply to jobs, which run to completion rather than serve traffic, or to clusters in your own cloud.

Scale to zero is the sharpest edge of active-CPU billing and working-set memory metering, because it removes an idle app’s cost entirely. It suits low-traffic personal projects, staging environments and preview deployments that sit unused for long stretches between visits.