-
Story
-
Resolution: Unresolved
-
Major
-
None
-
5
-
False
-
None
-
False
-
-
ACM-9641 - Hosted Cluster klusterlet management from ACM while MCE maintains HCP hosting
-
No
-
-
-
5
-
Installer Sprint 2024-34
Value Statement
In order to support epic https://issues.redhat.com/browse/ACM-11041, the hypershift addon agent is going to become the discovery agent to discover hosted clusters from MCE and create DiscoveredCluster resources in MCE's namespace in the ACM hub cluster. The hypershift addon agent will create, update and remove these DiscoveredCluster resources. Here is the sample DiscoveredCluster resource.
apiVersion: discovery.open-cluster-management.io/v1 kind: DiscoveredCluster metadata: creationTimestamp: "2024-05-09T01:31:49Z" generation: 2 labels: hypershift.open-cluster-management.io/hc-name: rj-0508a hypershift.open-cluster-management.io/hc-namespace: clusters name: rj-0508a namespace: local-cluster resourceVersion: "51271683" uid: ae3ed948-53e8-4a4c-8a60-1535331ee6bf spec: apiUrl: https://ad444596dab354e0b9fe2b8751c84479-464d8264d7f96e8d.elb.us-east-2.amazonaws.com:6443 cloudProvider: aws creationTimestamp: "2024-05-09T01:28:49Z" credential: {} displayName: local-cluster-rj-0508a isManagedCluster: false importAsManagedCluster: false name: rj-0508a openshiftVersion: 4.15.12 type: MultiClusterEngineHCP
The discover controller should handle MultiClusterEngineHCP type DiscoveredCluster differently when importAsManagedCluster is set to true.
It should create a KlusterletConfig resource to get the klusterlet installed in a non-default namespace for the discovered cluster. This can be shared for all DiscoveredCluster resources from the same MCE namespace.
apiVersion: config.open-cluster-management.io/v1alpha1 kind: KlusterletConfig metadata: name: <DiscoveredClusterNamespace>-config spec: # has to be prefix of open-cluster-management- and less than 57 character agentInstallNamespace: open-cluster-management-<DiscoveredClusterNamespace>
It should create a ManagedCluster resource with special annotations.
apiVersion: cluster.open-cluster-management.io/v1 kind: ManagedCluster metadata: annotations: import.open-cluster-management.io/hosting-cluster-name: <DiscoveredClusterNamespace> import.open-cluster-management.io/klusterlet-deploy-mode: Hosted open-cluster-management/created-via: hypershift agent.open-cluster-management.io/klusterlet-config: <DiscoveredClusterNamespace>-config name: $CLUSTER_NAME spec: hubAcceptsClient: true leaseDurationSeconds: 60
Create a klusterletaddonconfig resource that overrides the addon installation namespace. (still need to find out how from Qiu Jian)
Definition of Done for Engineering Story Owner (Checklist)
- ...
Development Complete
- The code is complete.
- Functionality is working.
- Any required downstream Docker file changes are made.
Tests Automated
- [ ] Unit/function tests have been automated and incorporated into the
build. - [ ] 100% automated unit/function test coverage for new or changed APIs.
Secure Design
- [ ] Security has been assessed and incorporated into your threat model.
Multidisciplinary Teams Readiness
- [ ] Create an informative documentation issue using the [Customer
Portal_doc_issue template](
https://github.com/stolostron/backlog/issues/new?assignees=&labels=squad%3Adoc&template=doc_issue.md&title=),
and ensure doc acceptance criteria is met. Link the development issue to
the doc issue. - [ ] Provide input to the QE team, and ensure QE acceptance criteria
(established between story owner and QE focal) are met.
Support Readiness
- [ ] The must-gather script has been updated.