相关疑难解决方法(0)

如何强制Kubernetes重新拉出图像?

我在GKE上的Kubernetes中有以下复制控制器:

apiVersion: v1
kind: ReplicationController
metadata:
  name: myapp
  labels:
    app: myapp
spec:
  replicas: 2
  selector:
    app: myapp
    deployment: initial
  template:
    metadata:
      labels:
        app: myapp
        deployment: initial
    spec:
      containers:
      - name: myapp
        image: myregistry.com/myapp:5c3dda6b
        ports:
        - containerPort: 80
      imagePullPolicy: Always
      imagePullSecrets:
        - name: myregistry.com-registry-key
Run Code Online (Sandbox Code Playgroud)

现在,如果我说

kubectl rolling-update myapp --image=us.gcr.io/project-107012/myapp:5c3dda6b
Run Code Online (Sandbox Code Playgroud)

执行滚动更新,但没有重新拉动.为什么?

pull image kubernetes

112
推荐指数
14
解决办法
8万
查看次数

标签 统计

image ×1

kubernetes ×1

pull ×1