云容器实例 CCI -更新Pod:响应示例
时间:2025-05-30 16:52:01
响应示例
状态码:200
OK
{ "apiVersion" : "v1", "kind" : "Pod", "metadata" : { "annotations" : { "kubernetes.io/availablezone" : "dc1", "network.alpha.kubernetes.io/network" : "[{\"name\":\"namespace-test-dc1-default-network\",\"interface\":\"eth0\",\"network_plane\":\"default\"}]" }, "creationTimestamp" : "2018-09-04T11:04:02Z", "labels" : { "name" : "pod-test2" }, "name" : "pod-test", "namespace" : "namespace-test", "resourceVersion" : "5254098", "selfLink" : "/api/v1/namespaces/namespace-test/pods/pod-test", "uid" : "3b99abe8-b032-11e8-9d5d-c88d83be759f" }, "spec" : { "containers" : [ { "image" : "redis:latest", "imagePullPolicy" : "Always", "name" : "test", "resources" : { "limits" : { "cpu" : "500m", "memory" : "1Gi" }, "requests" : { "cpu" : "500m", "memory" : "1Gi" } }, "terminationMessagePath" : "/dev/termination-log", "terminationMessagePolicy" : "File" } ], "dnsPolicy" : "ClusterFirst", "imagePullSecrets" : [ { "name" : "imagepull-secret" } ], "nodeName" : "c0dd6256-195a-e811-90a2-10c17294fcbc", "restartPolicy" : "Always", "schedulerName" : "default-scheduler", "securityContext" : { }, "tolerations" : [ { "effect" : "NoExecute", "key" : "node.kubernetes.io/not-ready", "operator" : "Exists", "tolerationSeconds" : 300 }, { "effect" : "NoExecute", "key" : "node.kubernetes.io/unreachable", "operator" : "Exists", "tolerationSeconds" : 300 } ] }, "status" : { "conditions" : [ { "lastProbeTime" : null, "lastTransitionTime" : "2018-09-04T11:04:03Z", "status" : "True", "type" : "Initialized" }, { "lastProbeTime" : null, "lastTransitionTime" : "2018-09-04T11:08:55Z", "message" : "containers with unready status: [test]", "reason" : "ContainersNotReady", "status" : "False", "type" : "Ready" }, { "lastProbeTime" : null, "lastTransitionTime" : "2018-09-04T11:04:02Z", "status" : "True", "type" : "PodScheduled" } ], "containerStatuses" : [ { "image" : "redis:latest", "imageID" : "", "lastState" : { "terminated" : { "containerID" : "docker://f867ab7d5c68a86fc695e4d3e5f1912fdb8f98f5029ca96032b4d5d407d9a75c", "exitCode" : 0, "finishedAt" : "2018-09-04T11:08:33Z", "reason" : "Completed", "startedAt" : "2018-09-04T11:04:23Z" } }, "name" : "test", "ready" : false, "restartCount" : 0, "state" : { "waiting" : { "message" : "rpc error: code = Unknown desc = Error response from daemon: Get https://registry-1.docker.io/v2/: net/http: request canceled while waiting for connection (Client.Timeout exceeded while awaiting headers)", "reason" : "ErrImagePull" } } } ], "hostIP" : "xxx.xxx.xxx.xxx", "phase" : "Running", "qosClass" : "Guaranteed", "startTime" : "2018-09-04T11:04:03Z" } }
support.huaweicloud.com/api-cci/patchCoreV1NamespacedPod.html