Version v1.39 of the documentation is no longer actively maintained. The site that you are currently viewing is an archived snapshot. For up-to-date documentation, see the latest version.
Deploy Status Checking
This page describes how Skaffold’s deployment status checking waits for deployed resources to become ready, and reports errors if they fails to stabilize within a certain time period.
Commands that trigger a deployment, like
skaffold run, and
skaffold apply, monitor select Kubernetes resources and wait for them to become ready.
Skaffold monitors the status of the following resource types:
Pod: check that the pod and its containers are in a
Deployment: check the output of
kubectl rollout status deploymentcommand
Stateful Sets: check the output of
kubectl rollout status statefulsetcommand
Status checking is enabled by default; it can be disabled with the
--status-check=falseflag, or by setting the
statusCheckfield of the deployment config stanza in the
If there are multiple skaffold
modulesactive, then setting
statusCheckfield of the deployment config stanza will only disable status-check for that config. However using the
--status-check=falseflag will disable it for all modules.
Deployed resource logs are suppressed until status-check passes. If you need the detailed logs to diagnose a status failure then rerun with the
Waiting for deployments to stabilize - default:deployment/leeroy-app Waiting for rollout to finish: 0 of 1 updated replicas are available... - default:deployment/leeroy-web Waiting for rollout to finish: 0 of 1 updated replicas are available... - default:deployment/leeroy-web is ready. [1/2 deployment(s) still pending] - default:deployment/leeroy-app is ready. Deployments stabilized in 2.168799605s
Configuring timeout for
You can also configure the time for deployments to stabilize with the
statusCheckDeadlineSeconds config field in the
For example, to configure deployments to stabilize within 5 minutes:
deploy: statusCheckDeadlineSeconds: 300
--status-check flag, for each
skaffold deploy will wait for
the time specified by
from the deployment configuration.
Deployment.spec.progressDeadlineSeconds is not set, Skaffold will either wait for
the time specified in the
statusCheckDeadlineSeconds field of the deployment config stanza in the
default to 10 minutes if this is not specified.
In the case that both
Deployment.spec.progressDeadlineSeconds are set, precedence
is given to
Deployment.spec.progressDeadline only if it is less than
For example, the
Deployment below with
progressDeadlineSeconds set to 5 minutes,
apiVersion: apps/v1 kind: Deployment metadata: name: getting-started spec: progressDeadlineSeconds: 300 template: spec: containers: - name: cannot-run image: gcr.io/k8s-skaffold/getting-started-foo
skaffold.yaml overrides the deadline to make sure deployment stabilizes in a 60 seconds,
apiVersion: skaffold/v1 deploy: statusCheckDeadlineSeconds: 60 kubectl: manifests: - k8s-*
skaffold deploy --status-check
will result in an error after waiting for 1 minute:
Tags used in deployment: Starting deploy... kubectl client version: 1.11+ kubectl version 1.12.0 or greater is recommended for use with Skaffold - deployment.apps/getting-started created Waiting for deployments to stabilize - default:deployment/getting-started Waiting for rollout to finish: 0 of 1 updated replicas are available... - default:deployment/getting-started failed. Error: received Ctrl-C or deployments could not stabilize within 1m: kubectl rollout status command interrupted. FATA 1/1 deployment(s) failed
status-check for multiple deployers or multiple modules
If you define multiple deployers, say
kustomize, all in the same skaffold config, or compose a multi-config project by importing other configs as dependencies, then the
status-check can be run in one of two ways:
- Single status check after all deployers are run. This is the default and it runs a single
status-checkat the end for resources deployed from all deployers across all skaffold configs.
- Per-deployer status check. This can be enabled by using the
--iterative-status-check=trueflag. This will run a
status-checkiteratively after every individual deployer runs. This can be especially useful when there are startup dependencies between services, or you need to strictly enforce the time and order in which resources are deployed.