ARO-HCP
AGENTS.md39 starsChanged 2 months agoApache-2.0View on GitHub
Load all of CLAUDE.md for context For all image bump related tasks, see tooling/image-updater/AGENTS.md. When assisting with operational troubleshooting tasks (stuck clusters, deletion issues, resource cleanup), the following context is essential. The deletion chain flows top-down through these layers. Deleting resources at a lower layer without removing the source above will cause them to be recreated: These are REST APIs accessed via kubectl exec, not CRDs:
Where files are headingNew AGENTS.md files have more rules about keeping secrets out of the code, and fewer about checking a change actually works.
Of the AGENTS.md files we read, the 11,773 first seen in the last six months, against the older ones: the kind of rule that gained most share, and the kind that lost most. About files like this in general, not this one, and an estimate, since a kind is a pattern in the words.
In this repository10 other files it gives its agents.
- config/AGENTS.mdAGENTS.md
- test/AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- config/CLAUDE.mdCLAUDE.md
- test/CLAUDE.mdCLAUDE.md
- test-integration/claude.mdCLAUDE.md
- .github/copilot-instructions.mdCopilot instructions
- bootstrap-api-versionSkill
- pr-standardsSkill
- agentic-workflowsSkill
The file
We split this AGENTS.md into the rules it gives an agent
5 rules. About 0 are common, 1 is distinctive, and 4 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈1
Distinctive · estimate
This author's own choices. Worth a look.
4
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 9
When assisting with operational troubleshooting tasks (stuck clusters, deletion issues, resource cleanup), the following context is …
- Very specific: line 33
Delete cluster: DELETE /api/aro_hcp/v1alpha1/clusters/<id> (MUST use aro_hcp endpoint, NOT clusters_mgmt)
- Very specific: line 62
Orphaned namespace bundles: When CS deletes a cluster, it may leave behind the *-00-hcp-namespaces ResourceBundle in Maestro.
- Very specific: line 63
Azure resources already gone: If the Azure resource group was deleted externally, the Hypershift operator will loop endlessly trying to …
- Very specific: line 64
CP namespace stuck Terminating: Check kubectl get namespace <ns> -o json | jq '.status.conditions' — the NamespaceContentRemaining …
≈ “Common” is an estimate: at least 1 in 5 of the 16,595 AGENTS.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Load all of CLAUDE.md for context
Image Bumps
For all image bump related tasks, see tooling/image-updater/AGENTS.md.
Operational Troubleshooting Context
When assisting with operational troubleshooting tasks (stuck clusters, deletion issues, resource cleanup), the following context is essential.
Cluster Access
- Management Cluster:
hcpctl mc breakglass <mc-name>— writes kubeconfig to a temp file, you mustexport KUBECONFIG=<path>from the output - Service Cluster:
hcpctl sc breakglass <svc-name>— same pattern, separate kubeconfig file - The kubeconfig paths are temporary and expire. If you get connection errors, the user needs to re-authenticate.
- Context names follow the pattern:
int-uksouth-mgmt-1,int-uksouth-svc-1, etc.
Architecture: Deletion Flow
The deletion chain flows top-down through these layers. Deleting resources at a lower layer without removing the source above will cause them to be recreated:
Clusters Service (API) → Maestro Server (ResourceBundle) → Maestro Agent → ManifestWork → HostedCluster → Control PlaneService Cluster APIs
These are REST APIs accessed via kubectl exec, not CRDs:
- Clusters Service (ns:
clusters-service, deployment:clusters-service, port 8000):- List clusters:
GET /api/clusters_mgmt/v1/clusters - Get cluster:
GET /api/clusters_mgmt/v1/clusters/<id> - Delete cluster:
DELETE /api/aro_hcp/v1alpha1/clusters/<id>(MUST usearo_hcpendpoint, NOTclusters_mgmt) - Container name:
clusters-service-server(use withkubectl exec -c clusters-service-server)
- List clusters:
- Maestro Server (ns:
maestro, deployment:maestro, port 8000):- List resource bundles:
GET /api/maestro/v1/resource-bundles - Get bundle:
GET /api/maestro/v1/resource-bundles/<id> - Delete bundle:
DELETE /api/maestro/v1/resource-bundles/<id> - Container name:
maestro-server - Resource bundles use UUIDs as names, not cluster IDs. Search by filtering manifest content with jq:
jq --arg cid "<cluster-id>" '.items[] | select(.manifests | tostring | test($cid))' - Namespace-only bundles have label
containsNamespaces: trueand create*-00-hcp-namespacesManifestWork
- List resource bundles:
Management Cluster Resources
- Namespaces:
ocm-${CLUSTER_PREFIX}-${CLUSTER_ID}(HostedCluster ns) andocm-${CLUSTER_PREFIX}-${CLUSTER_ID}-${CLUSTER_NAME}(Control Plane ns) - CLUSTER_PREFIX:
arohcpint(int),arohcpstg(stage),arohcpprod(prod) - ManifestWork in
local-clusternamespace, named by cluster ID - ManagedCluster is cluster-scoped, named by cluster ID
Common Finalizers That Block Deletion
| Finalizer | Resource | Controller |
hypershift.openshift.io/finalizer | HostedCluster, HostedControlPlane | Hypershift Operator |
hypershift.openshift.io/component-finalizer | Deployments in CP namespace | Hypershift Operator |
cluster.cluster.x-k8s.io | Cluster (CAPI) | Cluster API |
cluster.open-cluster-management.io/manifest-work-cleanup | ManifestWork | ACM Work Agent |
Known Issues
- Orphaned namespace bundles: When CS deletes a cluster, it may leave behind the
*-00-hcp-namespacesResourceBundle in Maestro. This causes the Maestro Agent to keep recreating the ManifestWork and namespace on the management cluster. Fix: delete the orphaned ResourceBundle from Maestro directly. - Azure resources already gone: If the Azure resource group was deleted externally, the Hypershift operator will loop endlessly trying to clean up non-existent resources. The
hypershift.openshift.io/finalizermust be removed manually. - CP namespace stuck Terminating: Check
kubectl get namespace <ns> -o json | jq '.status.conditions'— theNamespaceContentRemainingcondition lists exactly which resources and finalizers are blocking.
Operational Docs
- Cleanup Stuck Cluster Deletion — full troubleshooting procedure
- Fix Maestro Stale Resource Bundle
- HCP Cluster Creation Flow — includes component debug commands
- Postgres Breakglass
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

