Troubleshooting GitOps ZTP by validating the installation CRs
The ArgoCD pipeline uses the ClusterInstance and PolicyGenerator or PolicyGentemplate custom resources (CRs) to generate the cluster configuration CRs and Red Hat Advanced Cluster Management (RHACM) policies. Use the following steps to troubleshoot issues that might occur during this process.
-
You have installed the OpenShift CLI (
oc). -
You have logged in to the hub cluster as a user with
cluster-adminprivileges.
-
Check that the installation CRs were created by using the following command:
$ oc get AgentClusterInstall -n <cluster_name>If no object is returned, use the following steps to troubleshoot the ArgoCD pipeline flow from
ClusterInstancefiles to the installation CRs. -
Verify that the
ManagedClusterCR was generated using theClusterInstanceCR on the hub cluster:$ oc get managedcluster -
If the
ManagedClusteris missing, check if theclustersapplication failed to synchronize the files from the Git repository to the hub cluster:$ oc get applications.argoproj.io -n openshift-gitops clusters -o yaml