Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Multicluster support in antctl #3107

Closed
luolanzone opened this issue Dec 9, 2021 · 8 comments
Closed

Multicluster support in antctl #3107

luolanzone opened this issue Dec 9, 2021 · 8 comments
Labels
area/multi-cluster Issues or PRs related to multi cluster. kind/design Categorizes issue or PR as related to design. lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale.

Comments

@luolanzone
Copy link
Contributor

Describe what you are trying to solve

Since multi-cluster feature is under development, we need to add more commands to antctl to support multi-cluster feature to provide a better experience for MC ClusterSet initialization.

Describe the solution you have in mind

Add a sub-command mc to antctl so user can run antctl mc to trigger multi-cluster related commands.

Describe how your solution impacts user flows

User can use antctl to set up multi-cluster environment with better use experience.

Describe the main design/architecture of your solution

antctl mc should at least support below features.

  • initialize a leader cluster eg antctl mc deploy-leader
  • join a member cluster to an existing ClusterSet eg:antctl mc deploy-member
  • off-boarding a member cluster eg: antctl mc depart-member
  • show member and leader cluster information in a ClusterSet eg: antctl mc show clusterset
  • list exported MC resources antctl mc show resources

Alternative solutions that you considered

Test plan

Additional context

This is a part of issue #2770

@luolanzone luolanzone added kind/design Categorizes issue or PR as related to design. area/multi-cluster Issues or PRs related to multi cluster. labels Dec 9, 2021
@luolanzone
Copy link
Contributor Author

cc @hjiajing

@bangqipropel
Copy link
Contributor

question on this:
show seems like an important command in mc command, will we consider show as a keyword here? it seems like it means list for resources, but seems like get or describe for clusterset?

@luolanzone
Copy link
Contributor Author

There is a conclusion in a MC discussion meeting that we will support troubleshooting related feature in antctl for mc only, antrea operator will be the better place to do deployment/bootstrap related.

@luolanzone
Copy link
Contributor Author

luolanzone commented Jan 25, 2022

There a a few basic commands for antctl troubleshooting in MC after a discussion.

  1. antctl get clustersets [-n|--namespace ] [--kubeconfig]
    antctl can list all managed ClusterSets.
  2. antctl get clusterset $clusterset-name[-n|--namespace ] [--kubeconfig]
    antctl can show a ClusterSet details including the number of member/leader clusters, the ids of each cluster in the ClusterSet, and also the overall status
  3. antctl get serviceexports [--clusterid] [--kubeconfig] [--configs-path]
    antctl can get all exported Services by all member clusters in one line, and can also filter them by given member clusterid
    a similar output is like below:
Name      Namespace       ClusterID
service-a   default      member-cluster-a
service-b   demo         member-cluster-a
service-a   default      member-cluster-b
  1. antctl get serviceimports [--clusterid] [--kubeconfig] [--configs-path]
    antctl can get all imported Services by all member clusters in one line, and can also filter them by given member clusterid
    a similar output is like below:
Name                  Namespace       ClusterID
antrea-mc-service-a   default         member-cluster-a
antrea-mc-service-a   default         member-cluster-b
antrea-mc-service-b   demo            member-cluster-b
  1. antctl get resourceexport [--kubeconfig] [--clusterid]
    antctl can list all ResourceExports in a leader cluster and can also filter ResourcExport with given member clusterid
  2. print all mc antctl commands via one CLI.

@luolanzone
Copy link
Contributor Author

@aravindakidambi Could you help to take a look as well? welcome any suggestion. thanks

@github-actions
Copy link
Contributor

This issue is stale because it has been open 90 days with no activity. Remove stale label or comment, or this will be closed in 90 days

@github-actions github-actions bot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Apr 27, 2022
@luolanzone luolanzone removed the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Apr 27, 2022
@github-actions
Copy link
Contributor

This issue is stale because it has been open 90 days with no activity. Remove stale label or comment, or this will be closed in 90 days

@github-actions github-actions bot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Jul 27, 2022
@luolanzone
Copy link
Contributor Author

This is mainly done by #3287 and #3474, close this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/multi-cluster Issues or PRs related to multi cluster. kind/design Categorizes issue or PR as related to design. lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale.
Projects
None yet
Development

No branches or pull requests

2 participants