[Meshery Operator] Meshery Operator Deployment for Multi Cluster Management
#12.706 aberto em 21 de nov. de 2024
Métricas do repositório
- Stars
- (10.013 stars)
- Métricas de merge de PR
- (Mesclagem média 22d 16h) (332 fundiu PRs em 30d)
Description
_ See mesheryctl Command Tracker for current status of commands.
Replication Steps
To replicate this issue carry out the following steps:
- Create two independent minikube clusters using profiles e.g (
minikube start --driver=hyperkit -p profile1&minikube start —-driver=hyperkit -p profile2) - Switch to profile1 and deploy Meshery in the cluster.
- Navigate to the Meshery UI(Lifecycle > Connections), where profile1 should appear as a registered cluster.
- Ideally, profile2 should also be registered with the Meshery operator deployed, but this is not the case. To register profile2, switch to profile2 and run
mesheryctl system config minikube. This will upload the profile2 kubeconfig to the Meshery UI.
5. In the Meshery UI, click on each cluster to view the status of deployed operators and controllers
6. Profile1 correctly shows the Meshery operator as deployed, but profile2 does not have the operator deployed.
This issue tracks and aims to troubleshoot why profile2 is not properly showing the Meshery operator as deployed after registration and others.
Current Behavior
Meshery is a multi-cluster manager, leveraging the Meshery Operator. The Meshery Operator is a Kubernetes operator responsible for managing the lifecycle of critical Meshery components in each Kubernetes cluster.
The following relationships define how Meshery works with clusters:
-
One-to-One Relationship: Each Kubernetes cluster should have exactly one Meshery Operator deployed. This applies to both the cluster where the Meshery Server is running (e.g profile1) and any additional registered clusters (e.g., profile2).
-
Many-to-One Relationship: A single Meshery Server can manage multiple Kubernetes clusters, each with its own Meshery Operator.
However, there is an issue with the current behavior causing meshery not to identify and manage the second cluster:
- When profile1 (the cluster where the Meshery Server is deployed) is registered, the Meshery Operator is correctly deployed and its status is displayed in the UI.
- When profile2 (a second cluster added using its kubeconfig) is registered, the Meshery Operator is not deployed in this cluster, even though the cluster appears in the Meshery UI as a registered cluster.
This breaks the expected behavior where every cluster managed by Meshery should have its respective Meshery Operator deployed and actively managed.
In summary, we seem to have a broken API service in which Meshery Operators are not properly deployed to “registered” clusters.
Desired Behavior
When mesheryctl system start is executed, this should automatically initiate connections to all active clusters listed in the kubeconfig file. This includes registering each cluster in the Meshery UI and ensuring that the Meshery Operator is deployed in each active cluster.
Related Child Issues
- #12705
- #12707
- #12715
- #12716
Other Related Issues
- #12704
- #12717