Transfer cluster ownership on stage - RedHatInsights/uhc-portal GitHub Wiki
Premise
You can only transfer ROSA classic clusters as of 07/18/25. The transfer works on prod, but it can take up to 12 hours to complete. You can add a custom configmap to the cluster for stage to work (see below). From the front end perspective, the accept/decline/rescind is immediate and we can show it due to the status field so you do not necessarily need to complete a transfer.
Testing on stage
Create a transfer request
- Make a Rosa Classic cluster
- Initiate a transfer to another user by using the transfer ownership link in the actions dropdown on the cluster list page.
- Once a transfer is initiated, a new link will be on the Cluster List toolbar and an alert will be visible that links to the new cluster request page.
- From the owner view of the cluster request page, the owner can rescind the transfer from the table
- From the recipient view of the cluster request page, the recipient can Approve or decline the transfer.
- After a cluster is accepted by the recipient, a notification will show that the transfer is accepted and it may take up to 24 hours to complete. The request page will show the status as Transferring. NOTE: Stage API will not automatically transfer a cluster at this time without additional configuration. Prod API will work. See next chapter.
Force the transfer on stage
- On OCM UI: for cluster you are transferring, goto cluster overview -> Access Control
- Add a httpd idetity provider, let's say user=testuser
- Now go to Cluster Roles and Access
- Add "testuser" to cluster-admins
- Now open the console for that cluster (big blue "Open console" button at the top of cluster details)
- Login via httpd, using testuser and its password
- Once in, click the "+" on the top masthead
- A yaml editor should open, paste the following yaml into that and press create
kind: ConfigMap
apiVersion: v1
metadata:
name: insights-config
namespace: openshift-insights
data:
config.yaml: |
clusterTransfer:
interval: 2m
endpoint: https://api.stage.openshift.com/api/accounts_mgmt/v1/cluster_transfers/