istioctl multicluster link
Reference for the istioctl multicluster link command.
istioctl multicluster link
Link clusters for cross-cluster discovery through east-west gateways.
Synopsis
Link clusters in a multicluster ambient mesh to enable cross-cluster service discovery and route traffic through east-west gateways. The ‘istioctl mutlicluster link’ command creates Gateway resources in each cluster that use the ‘istio-remote’ GatewayClass. This class allows the gateways to connect to other clusters by using the addresses of their east-west gateways. You can link clusters bi-directionally or asymmetrically. Bi-directional links let services in any linked cluster send and receive traffic from any other linked cluster. Asymmetrical links allow traffic from the cluster(s) in ‘–from’ to the cluster(s) in ‘–to’, but not in reverse. Before linking, you can check the individual readiness of each cluster with ‘istioctl multicluster check’, and run it again after linking to confirm that the connections were successful.
istioctl multicluster link [flags]
Examples
# Link three clusters (alpha, beta, and gamma) bi-directionally for cross-cluster discovery
istioctl multicluster link --namespace istio-eastwest --contexts=alpha,beta,gamma
# Link clusters asymmetrically (alpha can reach beta, but beta cannot reach alpha)
istioctl multicluster link --namespace istio-eastwest --from alpha --to beta
# Generate the Gateway resources without applying them
istioctl multicluster link --namespace istio-eastwest --generate --context beta | kubectl apply -f - --context=alpha
Options
--contexts strings List of contexts to link bi-directionally. Verify that the contexts for all clusters are listed in your kubeconfig file by running 'kubectl config get-contexts'. If you have multiple kubeconfig files, you can generate a merged kubeconfig file by running 'KUBECONFIG=<kubeconfig_file1>.yaml:<file2>.yaml:<file3>.yaml kubectl config view --flatten'.
--from strings List of contexts to link to each 'to' cluster in an asymmetrical link.
--generate Only output the generated gateway YAML configuration instead of applying it.
-h, --help help for link
--preferred-data-plane-service-type string The service type that peered data plane connections can use with this gateway. Supported values are one of: loadbalancer, nodeport (default "loadbalancer")
-r, --revision string The revision to use.
--to strings List of contexts to link each 'from' cluster to in an asymmetrical link.
Options inherited from parent commands
--as string Username to impersonate for the operation. User could be a regular user or a service account in a namespace
--as-group stringArray Group to impersonate for the operation, this flag can be repeated to specify multiple groups.
--as-uid string UID to impersonate for the operation.
--context string Kubernetes configuration context
-i, --istioNamespace string Istio system namespace (default "istio-system")
--kubeclient-timeout string Kubernetes client timeout as a time.Duration string, defaults to 15 seconds. (default "15s")
-c, --kubeconfig string Kubernetes configuration file
-n, --namespace string Kubernetes namespace
--out string output directory (default "/tmp/istioctl-cli-docs/1.28")