Are there any problems running custom containers on the Kubernetes node wizard?

Many of the runs for deploying Kubernetes core nodes suggest using --register-schedulable=false to prevent user modules from loading into the node wizard (for example, https://coreos.com/kubernetes/docs/latest/deploy-master.html ). On a very small cluster, Kubernet seems like a somewhat wasteful computing resource to effectively prevent the use of the entire node for order planning, if absolutely necessary.

The answer to this question ( Will (maybe) Kubernetes run Docker containers on master node (s)?) Suggests that it is really possible to run user pods on master node - but does not take into account whether there are problems associated with resolving this.

The only information that I could find to date that suggests that there may be problems associated with the fact that it means that the containers on the main nodes seem to communicate unreliably (see http://kubernetes.io/docs/ admin / master-node-communication / and https://github.com/kubernetes/kubernetes/issues/13598 ). I suggest that this could potentially allow a fraudulent module running on the master node to access / capture the Kubernetes function, which is usually not available for containers on non-primary nodes. This is probably not very important if only internal containers are developed internally, although I assume that there is always the possibility of someone hacking access to the container / container and thereby gaining access to the node wizard.

Does this seem like a viable potential risk associated with this scenario (allowing the launch of custom containers on the Kubernetes node wizard)? Are there any other potential issues with this setup?

+3
source share
1 answer

Running pods on the main node are certainly possible.

The security risk that you mention is one of the problems, but if you set up service accounts, for all deployed containers there is really not so much to have secure remote access to local access to apirusver or insecure.

Another problem is resource conflict. If you run rogue modules on your host node, which destroys the core components, it can destabilize your entire cluster. Obviously, this is a concern for production deployments, but if you want to make the most of a small number of nodes in the development / experimentation environment, then it should be nice to run a few additional modules on the main server.

Finally, you need to make sure that the node wizard has a fairly large portion of cidr allocated to it. In some deployments, the wizard only gets / 30, which will prevent you from launching so many containers.

+2
source

Source: https://habr.com/ru/post/1266190/


All Articles