Ahmad
Ahmad

Reputation: 5760

Running other non-cluster containers on k8s node

I have a k8s cluster that runs the main workload and has a lot of nodes. I also have a node (I call it the special node) that some of special container are running on that that is NOT part of the cluster. The node has access to some resources that are required for those special containers. I want to be able to manage containers on the special node along with the cluster, and make it possible to access them inside the cluster, so the idea is to add the node to the cluster as a worker node and taint it to prevent normal workloads to be scheduled on it, and add tolerations on the pods running special containers.

The idea looks fine, but there may be a problem. There will be some other containers and non-container daemons and services running on the special node that are not managed by the cluster (they belong to other activities that have to be separated from the cluster). I'm not sure that will be a problem, but I have not seen running non-cluster containers along with pod containers on a worker node before, and I could not find a similar question on the web about that.

So please enlighten me, is it ok to have non-cluster containers and other daemon services on a worker node? Does is require some cautions, or I'm just worrying too much?

Upvotes: 1

Views: 204

Answers (1)

Kranthiveer Dontineni
Kranthiveer Dontineni

Reputation: 1533

Ahmad from the above description, I could understand that you are trying to deploy a kubernetes cluster using kudeadm or minikube or any other similar kind of solution. In this you have some servers and in those servers one is having some special functionality like GPU etc., for deploying your special pods you can use node selector and I hope you are already doing this.

Coming to running separate container runtime on one of these nodes you need to consider two points mainly

  1. This can be done and if you didn’t integrated the container runtime with kubernetes it will be one more software that is running on your server let’s say you used kubeadm on all the nodes and you want to run docker containers this will be separate provided you have drafted a proper architecture and configured separate isolated virtual network accordingly.
  2. Now comes the storage part, you need to create separate storage volumes for kubernetes and container runtime separately because if any one software gets failed or corrupted it should not affect the second one and also for providing the isolation.

If you maintain proper isolation starting from storage to network then you can run both kubernetes and container runtime separately however it is not a suggested way of implementation for production environments.

Upvotes: 1

Related Questions