LoginSignup
2
2

More than 3 years have passed since last update.

Kubernetes リソースが起動するのを待つ

Posted at

kubectl wait コマンドを使う。
https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#wait

下記では、app=sample にマッチするリソースが Ready になるのを待つ。

$ kubectl wait all -l app=sample --for condition=Ready

# --timeout でタイムアウト指定できる(デフォルト 30s)
$ kubectl wait all -l app=sample --for condition=Ready --timeout 5s
2
2
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
2
2