在https://cloud.google.com/kubernetes-engine/docs/tutorials/hello-app上可用的标准Hello应用程序不起作用。尽管在GCP上使用Kubernetes与Google结合使用时,事情应该立即开始工作,但似乎存在一些拉入问题。
例如,参考:https://kubernetes.io/docs/concepts/containers/images/#specifying-imagepullsecrets-on-a-pod
其中提到:
“使用Google Container在运行Google Compute Engine ( GCE )时,对Google容器注册表(GCR)有本机支持。如果您在GCE或Google Kubernetes引擎上运行集群,只需使用完整的映像名(例如gcr.io/my_project/ image :tag)。集群中的所有豆荚都可以读取此注册表中的图像访问权限。
我再次检查是否使用了正确的图像名称(复制,从容器注册表粘贴它)。
错误消息:
C:\Users\rober>kubectl get pods
NAME READY STATUS RESTARTS AGE
hello-web-694bc87958-rcdvg 0/1 ImagePullBackOff 0 7s
Type Reason Age From Message
---- ------ ---- ---- -------
Normal Scheduled 7m default-scheduler Successfully assigned default/hello-web-694bc87958-rcdvg to gke-hello-cluster-default-pool-9cbfb505-588j
Normal SandboxChanged 7m (x3 over 7m) kubelet, gke-hello-cluster-default-pool-9cbfb505-588j Pod sandbox changed, it will be killed and re-created.
Normal BackOff 7m (x6 over 7m) kubelet, gke-hello-cluster-default-pool-9cbfb505-588j Back-off pulling image "gcr.io/data-platform-tst/hello-app:v1"
Normal Pulling 6m (x3 over 7m) kubelet, gke-hello-cluster-default-pool-9cbfb505-588j pulling image "gcr.io/data-platform-tst/hello-app:v1"
Warning Failed 6m (x3 over 7m) kubelet, gke-hello-cluster-default-pool-9cbfb505-588j Failed to pull image "gcr.io/data-platform-tst/hello-app:v1": rpc error: code = Unknown desc = Error response from daemon: repository gcr.io/data-platform-tst/hello-app not found: does not exist or no pull access
Warning Failed 6m (x3 over 7m) kubelet, gke-hello-cluster-default-pool-9cbfb505-588j Error: ErrImagePull
Warning Failed 2m (x24 over 7m) kubelet, gke-hello-cluster-default-pool-9cbfb505-588j Error: ImagePullBackOffhttps://serverfault.com/questions/963638
复制相似问题