Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is there a way to manage multiple domains on a single Kubernetes cluster?

I work with a dev shop as a contractor & I'm pitching Kubernetes to my CTO.

It's on the premise that they can deploy multiple websites and abstract away multi-server management.

However, the one stipulation is that in this new cluster of resources they would be able to point multiple different domains at it and still be able to route requests accordingly.

So my question is: how can i manage multiple domains on a single Kubernetes cluster?

I don't know if this sort of thing is possible in Kubernetes, any help would be appreciated.

like image 313
Obinna Avatar asked Oct 21 '25 19:10

Obinna


1 Answers

You can use an ingress with multiple domain names:

https://kubernetes.io/docs/concepts/services-networking/ingress/

In the rules section, you can define multiple hosts like:

rules:
  - host: host1.com
    http:
      paths:
      ...
  - host: host2.com
    http:
      paths:
       ...
like image 58
Burak Serdar Avatar answered Oct 23 '25 18:10

Burak Serdar