This repository contains the GitOps configuration for the Runtime cluster. ArgoCD on the runtime cluster watches this repo and deploys whatever is promoted here by the Software Factory CI pipeline.
Factory CI pipeline finishes a build
│
▼
Pipeline commits updated manifests to this repo
(e.g. updates the image tag in deployment.yaml)
│
▼
ArgoCD on the runtime cluster detects the change
│
▼
Application is deployed to the runtime cluster
This is the GitOps promotion pattern: the factory cluster builds and tests, the runtime cluster runs. The two clusters are kept separate so a broken factory never affects the running application.
example-app/
namespace.yaml Namespace for the example application
deployment.yaml Deployment using Red Hat UBI httpd image
service.yaml ClusterIP service
route.yaml OpenShift Route with TLS edge termination
ansible/
bootstrap.yml Playbook for imperative setup steps (namespace creation, ConfigMaps, RBAC)
requirements.yml Ansible collection dependencies (kubernetes.core)
During the lab, the CI pipeline on the factory cluster will write to this repo as part of the promotion stage. Fork it into your GitLab instance and grant the pipeline service account write access.
Create an ArgoCD Application on the runtime cluster that points to your GitLab fork:
apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
name: example-app
namespace: openshift-gitops
spec:
project: default
source:
repoURL: https://<your-gitlab>/service-enablement-app-platform-runtime-gitops.git
targetRevision: main
path: example-app
destination:
server: https://kubernetes.default.svc
namespace: example-app
syncPolicy:
automated:
prune: true
selfHeal: trueThe ansible/bootstrap.yml playbook handles tasks that cannot be expressed declaratively — for example, creating namespaces or configuring RBAC before ArgoCD first syncs.
# Install required collections
ansible-galaxy collection install -r ansible/requirements.yml
# Run the bootstrap playbook
ansible-playbook ansible/bootstrap.ymlThe example-app directory contains a minimal OpenShift application (Red Hat UBI httpd) that serves as the promotion target. In a real pipeline, the CI job on the factory cluster would update the image tag in deployment.yaml and commit it here — ArgoCD then picks up the change and rolls out the new version automatically.
The factory cluster GitOps config lives in: service-enablement-app-platform-factory-gitops