Basic floating interdomain examples includes the next setup:
Interdomain tests can be on two clusters, for thus tests scheme of request will look as:
- Load balancer
- Interdomain DNS
- Interdomain spire
- Kernel to Ethernet to Kernel Connection
- Kernel to Ethernet to Kernel Connection via floating registry
- Kernel to IP to Kernel Connection
- Kernel to IP to Kernel Connection via floating registry
- DNS
- Floating DNS
- Floating VL3
- Floating VL3_scale_from_zero
- Floating VL3 DNS
- Floating NSE Composition
1. Apply deployments for cluster1: Apply NSM resources for basic tests:
kubectl --kubeconfig=$KUBECONFIG1 apply -k https://github.com/networkservicemesh/deployments-k8s/examples/multicluster/clusters-configuration/cluster1?ref=c9dc6831a1647494d4dc2581a362ed21a42685f9
Wait for nsmgr-proxy-service exposing:
kubectl --kubeconfig=$KUBECONFIG1 get services nsmgr-proxy -n nsm-system -o go-template='{{index (index (index (index .status "loadBalancer") "ingress") 0) "ip"}}'
Wait for admission-webhook-k8s:
WH=$(kubectl --kubeconfig=$KUBECONFIG1 get pods -l app=admission-webhook-k8s -n nsm-system --template '{{range .items}}{{.metadata.name}}{{"\n"}}{{end}}')
kubectl --kubeconfig=$KUBECONFIG1 wait --for=condition=ready --timeout=1m pod ${WH} -n nsm-system
2. Apply deployments for cluster2:
Apply NSM resources for basic tests:
kubectl --kubeconfig=$KUBECONFIG2 apply -k https://github.com/networkservicemesh/deployments-k8s/examples/multicluster/clusters-configuration/cluster2?ref=c9dc6831a1647494d4dc2581a362ed21a42685f9
Wait for nsmgr-proxy-service exposing:
kubectl --kubeconfig=$KUBECONFIG2 get services nsmgr-proxy -n nsm-system -o go-template='{{index (index (index (index .status "loadBalancer") "ingress") 0) "ip"}}'
Wait for admission-webhook-k8s:
WH=$(kubectl --kubeconfig=$KUBECONFIG2 get pods -l app=admission-webhook-k8s -n nsm-system --template '{{range .items}}{{.metadata.name}}{{"\n"}}{{end}}')
kubectl --kubeconfig=$KUBECONFIG2 wait --for=condition=ready --timeout=1m pod ${WH} -n nsm-system
3. Apply deployments for cluster3:
Apply NSM resources for basic tests:
kubectl --kubeconfig=$KUBECONFIG3 apply -k https://github.com/networkservicemesh/deployments-k8s/examples/multicluster/clusters-configuration/cluster3?ref=c9dc6831a1647494d4dc2581a362ed21a42685f9
Wait for nsmgr-proxy-service exposing:
kubectl --kubeconfig=$KUBECONFIG3 get services registry -n nsm-system -o go-template='{{index (index (index (index .status "loadBalancer") "ingress") 0) "ip"}}'
To free resouces follow the next command:
WH=$(kubectl --kubeconfig=$KUBECONFIG1 get pods -l app=admission-webhook-k8s -n nsm-system --template '{{range .items}}{{.metadata.name}}{{"\n"}}{{end}}')
kubectl --kubeconfig=$KUBECONFIG1 delete mutatingwebhookconfiguration ${WH}
kubectl --kubeconfig=$KUBECONFIG1 delete ns nsm-system
WH=$(kubectl --kubeconfig=$KUBECONFIG2 get pods -l app=admission-webhook-k8s -n nsm-system --template '{{range .items}}{{.metadata.name}}{{"\n"}}{{end}}')
kubectl --kubeconfig=$KUBECONFIG2 delete mutatingwebhookconfiguration ${WH}
kubectl --kubeconfig=$KUBECONFIG2 delete ns nsm-system
kubectl --kubeconfig=$KUBECONFIG3 delete ns nsm-system