https://rancher.com/ logo
Title
p

proud-ram-62490

04/21/2023, 7:23 PM
I currently have a single node docker setup for rancher and am in the process of migrating it to an RKE2 cluster. The only problem I’m seeing so far is that Rancher is currently exposed on an ip - is there a way to deploy rancher on the new cluster via Metallb and the same IP?
c

creamy-pencil-82913

04/21/2023, 7:26 PM
if you install metallb and configure rke2-ingress-nginx to use a LoadBalancer service instead of running as a node port, yes
but that is all going to be something you will need to manage outside of Rancher
Rancher just sets itself up behind an Ingress, so it’ll be available via however you expose ingress-nginx
p

proud-ram-62490

04/21/2023, 7:28 PM
I have metallb setup and ready, any tips for configuring rke2-ingress-nginx for using metallb?
NVM, I think I’ve got it.
Maybe I don’t.
c

creamy-pencil-82913

04/21/2023, 7:30 PM
you’d want to use a HelmChartConfig and set the chart values to enable it
p

proud-ram-62490

04/21/2023, 7:30 PM
I want to put rancher on the load balancer directly, not specifically nginx
c

creamy-pencil-82913

04/21/2023, 7:31 PM
It doesn’t work like that. when you deploy Rancher to a Kubernetes cluster, it needs to be behind an ingress.
You only expose Rancher directly when it’s running in the (unsupported) docker container
p

proud-ram-62490

04/21/2023, 7:32 PM
Is there a guide some where for migrating away from that successfully?
Thanks for this much at least.
This will cause my Rancher hostname to change, which I read will break things.. Just trying to avoid that in general.
p

proud-ram-62490

04/21/2023, 7:32 PM
So I did the migration, that’s done.
But all of my current clusters (all two lol) are looking for 192.168.10.99 as the host, not mysweetrancher.me.com
c

creamy-pencil-82913

04/21/2023, 7:33 PM
if you’re using MetalLB, you should be able to just assign the MetalLB the same address that you were previously using for the docker container?
ah yeah, registering all your clusters against an IP would be an anti-pattern. Thats why the docs and UI all wants you to put in a hostname for Rancher.
p

proud-ram-62490

04/21/2023, 7:34 PM
Well, I was learning and things got out of hand, very antipattern lol
I realize that my current setup is not ideal, and is antipattern - I’d be happy to set it up properly. Is there a recommended doc or guide or even an uncrecommended doc/guide for migrating these clusters to the new hostname?
c

creamy-pencil-82913

04/21/2023, 7:37 PM
I’m not sure. I’m more of an RKE2/K3s dev than a Rancher dev but from what I know you’re looking at changing both the rancher cert and rancher hostname on the downstream clusters.
p

proud-ram-62490

04/21/2023, 7:44 PM
Thanks for the support Brandon.