static pod

Posted allenhaozi

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了static pod相关的知识,希望对你有一定的参考价值。

If you are running clustered Kubernetes and are using static pods to run a pod on every node, you should probably be using a DaemonSet!

Static pods are managed directly by kubelet daemon on a specific node, without the API server observing it. It does not have an associated replication controller, and kubelet daemon itself watches it and restarts it when it crashes. There is no health check. Static pods are always bound to one kubelet daemon and always run on the same node with it.

Kubelet automatically tries to create a mirror pod on the Kubernetes API server for each static pod. This means that the pods are visible on the API server but cannot be controlled from there.

 

When kubelet starts, it automatically starts all pods defined in directory specified in --pod-manifest-path= or --manifest-url= arguments or add the staticPodPath: <the directory> field in the KubeletConfiguration file, i.e. our static-web. (It may take some time to pull nginx image, be patient…):

 

 

文档: 

https://kubernetes.io/docs/tasks/administer-cluster/static-pod/

以上是关于static pod的主要内容,如果未能解决你的问题,请参考以下文章

static

JAVA! static啥作用?

static变量问题

static变量以及方法

Java面向对象4----static关键字

Java面向对象4----static关键字