You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Add delete service account resources
* Test pass for delete service account resources
* Add label managed-by to resources when being created during reconciliation
* Fix DisconnectCluster function to include retrieving service account name and cluster role binding name and delete resources accordingly
* Add gitops disconnect cluster cmd
* Add service account name and cluster role binding name flags to gitops disconnect cmd
Add check service account name and check cluster role binding name functions to verify their existance with the connect-cluster label
* Add existing resources to simpleClientSet when creating it instead of using helper function in service account tests
* Make newGitopsClusterScheme unexposed
* Move prerun disinheritApiFlags to new function in common app pkg in cmd gitops pkg dir
* update go.mod
Short: "Disconnect cluster from remote cluster by deleting resources",
28
+
Example: `
29
+
# Disconnect cluster
30
+
gitops disconnect cluster [PARAMS] <CLUSTER_NAME>
31
+
`,
32
+
SilenceUsage: true,
33
+
SilenceErrors: true,
34
+
Args: cobra.MinimumNArgs(1),
35
+
RunE: disconnectClusterCmdRunE(opts),
36
+
}
37
+
38
+
cmd.Flags().StringVar(&disconnectOptionsCmdFlags.RemoteClusterContext, "connect-context", "", "Context name of the remote cluster")
39
+
cmd.Flags().StringVar(&disconnectOptionsCmdFlags.ServiceAccountName, "service-account", "weave-gitops-enterprise", "Service account name to be created/used")
40
+
cmd.Flags().StringVar(&disconnectOptionsCmdFlags.ClusterRoleBindingName, "cluster-role-binding", "weave-gitops-enterprise", "Cluster role binding name to be created/used")
41
+
cmd.Flags().StringVarP(&disconnectOptionsCmdFlags.Namespace, "namespace", "n", "default", "Namespace of remote cluster")
42
+
cmd.Flags().StringVarP(&disconnectOptionsCmdFlags.Debug, "debug", "d", "INFO", "Verbose level of logs")
0 commit comments