我就是这么做的:
部署有状态集。在状态CrashLoopBackOff:kubectl apply -f error.yaml中,吊舱总是以错误的方式退出,以引发失败的吊舱。
更改error.yaml (echo a => echo b)并重新部署有状态集:kubectl apply -f error.yaml
Pod保持错误状态,不会立即重新部署,但等待某个时间后重新启动。
请求pod状态:
$ kubectl get pod errordemo-0
NAME READY STATUS RESTARTS AGE
er
我正试图在kubernetes集群中创建Pod,以启动码头映像。我使用版本8.0.0来创建pod集群。我使用这个文档来创建Pod集群。但我无法为码头集装箱设置环境变量。
代码:
Map<String, String> attributes = myObject.getAttributes(); //need to set this attributes as environment variables in pod creation
// create pod of a Kubernetes cluster
V1Pod pod = new V1PodBuilder().withNe