This directory contains configuration files that helps installing the Runtime Component operator
using kustomize with Argo CD. These configurations
are useful when using Red Hat® OpenShift® GitOps Operator to manage Argo CD Applications within a Red Hat® OpenShift® Container Platform cluster.
Red Hat® OpenShift® GitOps is based on the open source project Argo CD and provides a similar set of features to what the upstream offers, with additional automation and integration into Red Hat® OpenShift® Container Platform. Hence, these configurations are also transferable when using Argo CD Operator standalone within a Kubernetes cluster.
-
Install Red Hat® OpenShift® GitOps Operator from OpenShift® UI into the
openshift-gitops-operatornamespace. -
Grant cluster-admin permissions for the GitOps operator to be able to create Custom Resource Definitions for Runtime Component operator.
oc adm policy add-cluster-role-to-user cluster-admin system:serviceaccount:openshift-gitops:openshift-gitops-argocd-application-controller -n openshift-gitops
-
Follow the steps below for one of the three install modes:
-
You can choose to modify the default namespace(s) by updating
.spec.source.kustomize.namespaceand.spec.destination.namespacein theApplicationcustom resource(s). -
(Optional) Ignore runtime artifacts generated by Runtime Component operator such as the
runtime-component-operatorConfigMap by editing the Application custom resource.
This Argo CD Application installs the operator into the 'runtime-component' namespace,
and the operator watches for Runtime Component custom resource instances only in its own namespace. To install, run: kubectl apply -f kustomize-rco-own-namespace.yaml and to uninstall, run: kubectl delete -f kustomize-rco-own-namespace.yaml
These Argo CD Applications install the operator into the namespace 'rco-ns', but configures it to
watch for Runtime Component custom resource instances in a different namespace called 'rco-watched-ns'. To install, run: kubectl apply -f kustomize-rco-another-namespace.yaml
This Argo CD Application installs the operator into the 'runtime-component' namespace,
but configures it to watch for Runtime Component custom resource instances in any namespaces.
Compared to the OwnNamespace configuration, this Application requires additional ClusterRoles and ClusterRoleBindings.
To install, run: kubectl apply -f kustomize-rco-all-namespaces.yaml