Pod lifecycle & states
Every pod moves through five states. The state decides what is billed and which actions are allowed.
States
| Status | Meaning | Billed |
|---|---|---|
CREATED | The pod object exists and is waiting for a host with a free GPU of the requested type. | Nothing |
PROVISIONING | A host is assigned. The image is being pulled, disks are allocated and the container is starting. | Nothing |
RUNNING | The container is running and its ports are reachable. | GPU, container disk and volume disk |
EXITED | The container stopped, either because you stopped it or because its main process exited. The GPU is released; the volume disk is kept. | Volume disk at the stopped rate |
TERMINATED | The pod and its container disk and volume disk are deleted. Network volumes are not affected. Terminal state. | Nothing |
Transitions
CREATED ──► PROVISIONING ──► RUNNING ──stop / process exits──► EXITED
▲ │ │
│ └──restart (same host) │
└──────────── start ◄─────────────┘
any state ──terminate (DELETE /pods/{podId})──► TERMINATEDCREATED → PROVISIONING: a host with a free GPU of the requested type was found.PROVISIONING → RUNNING: the image was pulled, disks were mounted and the container started.RUNNING → EXITED: you calledstop, the container's main process exited, or your balance reached zero.EXITED → PROVISIONING: you calledstart. The pod restarts on the same host.* → TERMINATED: you calledDELETE /pods/{podId}. This cannot be undone.
status and desiredStatus
status is what the pod is doing right now. desiredStatus is what you asked for: RUNNING, EXITED or TERMINATED. They differ while a transition is in progress, for example right after start the pod has desiredStatus: "RUNNING" and status: "PROVISIONING".
If status is EXITED while desiredStatus is still RUNNING, the container's main process exited on its own. Check lastExitCode and the logs. Pods do not restart automatically.
Allowed actions per state
| Action | CREATED | PROVISIONING | RUNNING | EXITED |
|---|---|---|---|---|
start | – | – | – | Yes |
stop | Yes | Yes | Yes | – |
restart | – | – | Yes | – |
PATCH | Yes | Yes | Yes (restarts the pod) | Yes |
DELETE | Yes | Yes | Yes | Yes |
Calling an action that is not allowed returns 409 invalid_state. TERMINATED pods accept no actions and disappear from GET /pods after 24 hours.
Reacting to state changes
Subscribe to pod.created, pod.running, pod.exited and pod.terminated with an account webhook instead of polling. Each event carries the full pod object in data.object.