-
Notifications
You must be signed in to change notification settings - Fork 0
Access tenant thru NodePort
Allan Roger Reid edited this page Mar 14, 2023
·
1 revision
- Edit the tenant console service:
k -n <tenant namespace> edit svc/<tenant name>-console
- If using kind, you need to have had defined some extraPortMappings (see example https://github.com/cniackz/public/wiki/nodeport-for-operator-login). Sample kind-config.yaml for
kind create cluster --config "kind-config.yaml"
kind: Cluster
apiVersion: kind.x-k8s.io/v1alpha4
networking:
apiServerAddress: "127.0.0.1"
apiServerPort: 6443
nodes:
- role: control-plane
extraPortMappings:
- containerPort: 30080
hostPort: 30080
listenAddress: "127.0.0.1"
protocol: TCP
- role: worker
extraPortMappings:
- containerPort: 30081
hostPort: 30081
listenAddress: "127.0.0.1"
protocol: TCP
- role: worker
extraPortMappings:
- containerPort: 30082
hostPort: 30082
listenAddress: "127.0.0.1"
protocol: TCP
- role: worker
extraPortMappings:
- containerPort: 30083
hostPort: 30083
listenAddress: "127.0.0.1"
protocol: TCP
- role: worker
extraPortMappings:
- containerPort: 30084
hostPort: 30084
listenAddress: "127.0.0.1"
protocol: TCP
- Then bind the tenant console port to one of the unused ports under:
spec
ports:
- name: http-console
nodePort: 30081 #In this case I had already used 30080 for the minio console
- Access the tenant using e.g. http://localhost:30081/