首页 文章

NGINX Plus容器抛出错误,因为找不到nginxplus可执行文件

提问于
浏览
1

我部署nginxplus容器时遇到错误:

Events:
  Type     Reason                 Age               From                               Message
  ----     ------                 ----              ----                               -------
  Normal   Scheduled              1m                default-scheduler                  Successfully assigned nginx-ingress-744f8c7d8-mtx5c to aks-nodepool1-39499429-1
  Normal   SuccessfulMountVolume  1m                kubelet, aks-nodepool1-39499429-1  MountVolume.SetUp succeeded for volume "nginx-ingress-token-lzp54"
  Normal   Pulling                1m                kubelet, aks-nodepool1-39499429-1  pulling image "**.azurecr.io/nginxplus:v2"
  Normal   Pulled                 1m                kubelet, aks-nodepool1-39499429-1  Successfully pulled image "**.azurecr.io/nginxplus:v2"
  Warning  BackOff                56s (x3 over 1m)  kubelet, aks-nodepool1-39499429-1  Back-off restarting failed container
  Normal   Pulled                 41s (x3 over 1m)  kubelet, aks-nodepool1-39499429-1  Container image "**.azurecr.io/nginxplus:v2" already present on machine
  Normal   Created                40s (x4 over 1m)  kubelet, aks-nodepool1-39499429-1  Created container
  Warning  Failed                 40s (x4 over 1m)  kubelet, aks-nodepool1-39499429-1  Error: failed to start container "nginxplus": executable not found in $PATH
  Warning  FailedSync             28s (x8 over 1m)  kubelet, aks-nodepool1-39499429-1  Error syncing pod

我使用了https://www.nginx.com/blog/deploying-nginx-nginx-plus-docker/的nginxplus dockerfile

我使用了https://github.com/nginxinc/kubernetes-ingress/blob/master/install/deployment/nginx-plus-ingress.yaml的入口控制器文件

Pod日志更新:

这是我尝试检索pod日志时得到的 .

$ kubectl get pods -n nginx-ingress
NAME                            READY     STATUS             RESTARTS   AGE
nginx-ingress-744f8c7d8-mtx5c   0/1       CrashLoopBackOff   39         2h  

$ kubectl logs nginx-ingress-744f8c7d8-mtx5c -n nginx-ingress
failed to open log file "/var/log/pods/e6ed4c91-0fb7-11e8-b1bc-0a58ac1f1223/nginxplus_39.log": open /var/log/pods/e6ed4c91-0fb7-11e8-b1bc-0a58ac1f1223/nginxplus_39.log: no such file or directory

请帮忙!!

1 回答

相关问题