Overview

Cloud Pak for Integration puts integration runtimes on Kubernetes. The ACE operator runs integration servers as custom resources. The MQ operator runs queue managers. API Connect publishes products to catalogs. All of it is declarative. That makes GitOps possible. It does not make it happen.

A common first move to OpenShift keeps the old habits. A pipeline watches one repository. On every push it renders the configuration and applies it to the cluster. Other pipelines are started by hand. API products are published by a separate manual run. It works most days. On the other days it is hard to say what is running, or why.

The alternative is a pull model. CI (GitLab CI in the examples) builds and tests. Argo CD, one instance per cluster, reconciles each cluster to its own environment repository. Compliance checks live in shared CI templates. An API registry records every API, its consumers and its SLA. The rest of this article is the detail. The examples use IBM’s integration stack, but the rules carry over unchanged to any operator-managed integration runtime — Apache Camel K, MuleSoft Runtime Fabric, Kong, RabbitMQ or Kafka on Kubernetes.

Two neighbouring articles cover adjacent ground. Tekton & ArgoCD covers the generic pipeline shape, secrets and image signing. Multi-Cluster GitOps covers hub-spoke fleets with ApplicationSet generators. This one is specific to integration runtimes, and it deliberately does not use a hub.

What a Push Model Gets Wrong

Start with an honest defect list. Build it by reading the pipeline code and comparing it with what is actually on the cluster, not from what the pipeline is supposed to do. The items below are the defects that appear most often in push-based integration pipelines.

DefectWhat happensConsequence
Whole-environment applyEvery push to the main branch re-renders and re-applies the entire environment: MQ, API Connect, every integration serverOne team’s change redeploys every team. One broken file blocks all deployments.
Wrong revisionThe trigger passes the commit SHA. The pipeline ignores it and clones the branch head.A run deploys whatever the branch holds at run time, not the commit that triggered it. No traceability.
No pruneResources are applied, never prunedDeleting a file in Git changes nothing. Orphans accumulate. Rollback is manual.
Mutable buildsBAR files are published as latest, followed by a rollout restartThe tested build cannot be promoted unchanged. There is no known version to roll back to.
Manual side doorsPer-platform pipelines accept any branch and any pathUnreviewed code can reach a cluster. The cluster drifts from Git.
Manual API publishingAPI products are published by a separate, hand-started runAPIs are not promoted with the integrations behind them
None of these is exotic

Each defect is a reasonable shortcut taken under deadline. Together they mean you cannot answer the auditor’s first question: “which approved commit is running in production?” Patching them one by one inside a push model still leaves you without drift detection. A cluster’s state stays whatever the last run left behind.

Ten Rules

Write the target as ten normative rules. Each one closes a defect or a class of defects. Short rules are easier to enforce in code and easier to defend in review.

  1. CI never touches a cluster

    CI builds, tests, publishes immutable artefacts and opens merge requests. It holds no cluster credentials. Only Argo CD changes platform namespaces.

  2. One Argo CD per cluster, one configuration repository per environment

    Each cluster’s Argo CD reads only its own environment repository. Environments never share a repository or a branch.

  3. One Argo application per platform per environment

    The blast radius of any change is one platform in one environment. Each platform has its own AppProject and namespace.

  4. No floating versions

    Runtime, BAR, chart and image versions are pinned. The chart and the tooling reject latest, ranges and empty values.

  5. Promotion is a merge request; rollback is a revert

    The same versions move from dev to test to uat to prod by merge request. Nothing is rebuilt between environments.

  6. Sync policy follows risk

    Lower environments auto-sync with prune and self-heal. Production detects drift but syncs manually, after an approved merge, outside freeze windows.

  7. Configuration is readable, layered and hashed

    Three layers of readable sources, packaged with content hashes so a configuration change restarts exactly the servers that use it.

  8. MQ objects are applied by an idempotent pre-sync Job

    Queues and channels belong to the platform that uses them and change with it.

  9. API products publish after servers are healthy

    An API is never live in front of an integration that is not.

  10. Secrets sit behind a provider switch

    Credentials can stay in their current store, but the chart reads them through a secrets.provider switch. Moving to Vault later changes one value, not the layout.

Repositories, Environments, Argo CD

The repository model is the architecture. Get it wrong and every rule above becomes a convention rather than a fact. Five kinds of repository are enough, each with one owner.

RepositoryContainsOwner
Delivery repos (one per integration)ACE source, OpenAPI specs, tests, a short .gitlab-ci.ymlDelivery team
Shared CI templatesVersioned pipeline templates, including the compliance jobsPlatform team
Chart repoThe Helm chart that renders a platform, plus the configuration packaging tool; released by tagPlatform team
GitOps control repoArgo CD instances, AppProjects, ApplicationSets, namespacesPlatform team
Environment repos (one each for dev, test, uat, prod)Values and configuration sources only: shared/ and platforms/<name>/CODEOWNERS per platform folder; prod merges restricted

Why one Argo CD per cluster rather than a hub? Two reasons. First, environment isolation becomes physical. The prod Argo CD has no credentials for dev, and the dev Argo CD has none for prod. Second, a hub is a shared failure domain and a shared approval surface. In a regulated environment, a separate production control plane is easier to explain than a hub with careful RBAC. The trade-off is more Argo CD instances to upgrade. Red Hat OpenShift GitOps makes that an operator upgrade, not a project.

One Application per Platform per Environment

A “platform” here is a business-aligned group of integration servers, their configurations, their MQ objects and their API products. Each platform gets one folder in each environment repository. An ApplicationSet in that cluster turns each folder into exactly one Argo CD Application.

The Application is multi-source. The chart comes from the chart repo at a pinned tag. The values come from the environment repo. Each platform folder carries a small descriptor that pins its chart version, so platforms can upgrade the chart one at a time.

applicationset-platforms.yamlyaml
apiVersion: argoproj.io/v1alpha1
kind: ApplicationSet
metadata:
  name: integration-platforms
  namespace: integration-gitops          # this cluster's own Argo CD
spec:
  goTemplate: true
  generators:
    - git:
        repoURL: https://git.example.com/ops/deploy-dev.git
        revision: main
        files:
          - path: platforms/*/platform.yaml   # one file = one Application
  template:
    metadata:
      name: '{{ .platform.name }}-dev'
    spec:
      project: '{{ .platform.name }}'       # AppProject per platform
      destination:
        server: https://kubernetes.default.svc
        namespace: '{{ .platform.namespace }}'
      sources:
        - repoURL: https://git.example.com/platform/integration-charts.git
          path: charts/ace-platform
          targetRevision: '{{ .chart.version }}'  # a tag, never a branch
          helm:
            valueFiles:
              - $values/shared/values.yaml
              - '$values/platforms/{{ .platform.name }}/values.yaml'
        - repoURL: https://git.example.com/ops/deploy-dev.git
          targetRevision: main
          ref: values
      syncPolicy:
        automated:
          prune: true
          selfHeal: true
        syncOptions:
          - PruneLast=true
platforms/orders/platform.yamlyaml
platform:
  name: orders
  namespace: int-orders
chart:
  version: ace-platform-2.3.1   # bumped per platform, by MR

The AppProject is the fence. It limits the platform to its own namespace and to the kinds it is allowed to own. Shared objects — namespaces, common policies, bar-download credentials — are referenced by a platform, never owned by it. That stops a prune in one platform from deleting something another platform needs.

One resource, one owner

During migration, the old push pipeline and Argo CD can both believe they own an integration server. They will fight. Self-heal reverts the pipeline’s change; the next push reverts Argo’s. Onboard a platform only after it has been removed from the old pipeline, and agree that hand-over with the owning team in writing.

Configuration in Three Layers

ACE configuration is the hard part. Policy projects, server configuration, generic files and credentials all become operator Configuration resources. Many teams commit them as opaque base64 zips. Nobody can review a zip in a merge request.

Keep configuration as readable sources in three layers:

  • Environment-shared (shared/) — runtime version, common policies, defaults. Owned by the platform team.
  • Platform (platforms/<name>/config/) — policy projects and server configuration for that platform. Owned by the delivery team.
  • Environment values (platforms/<name>/values.yaml) — replicas, BAR versions, endpoints that differ per environment.

A small packaging tool zips each source folder into a generated directory and names it with a content hash. The environment pipeline checks on every merge request that the generated output matches its sources. If someone edits the zip by hand, the check fails.

platforms/orders/values.yamlyaml
integrationServers:
  - name: orders-api
    replicas: 2
    bars:
      - name: orders-api
        version: 1.8.0-4f2c9ab          # CI bumps this line by MR
    configurations:
      - orders-policies                 # from platforms/orders/config/
      - orders-server-conf
      - common-policies                 # referenced, owned by shared/
secrets:
  provider: repo                         # current store; later: vault, same layout

The hash does the restart work. A Configuration name includes the first characters of its content hash. Change one policy file and the name changes. The integration server’s configurations list changes with it. The operator rolls only the servers that reference it. No manual rollout restart. No restarting servers whose configuration did not change.

charts/ace-platform/templates/configurations.yaml (excerpt, Helm template)helm
{{- /* Reject floating versions before anything renders. */}}
{{- $rt := required "shared.aceVersion is required" .Values.shared.aceVersion }}
{{- if regexMatch "(?i)latest|[*^~]|^$" $rt }}
{{- fail (printf "floating ACE version not allowed: %s" $rt) }}
{{- end }}

{{- range $name, $c := .Values.generated.configurations }}
apiVersion: appconnect.ibm.com/v1beta1
kind: Configuration
metadata:
  name: {{ $name }}-{{ $c.hash | trunc 8 }}   # content hash in the name
spec:
  type: {{ $c.type }}                      # policyproject, serverconf, generic
  data: {{ $c.data }}                      # packaged from readable sources
---
{{- end }}
Why not a config-management plugin?

Argo CD can run custom plugins to render manifests. Avoid them here. A plugin is code inside the repo server that nobody reviews with the change, and it makes local rendering differ from cluster rendering. Plain Helm plus a checked, generated directory renders the same everywhere. The pipeline can run helm template on every merge request and show the diff.

MQ Objects and API Products

Queues and API products are part of a platform. If they deploy separately, they drift separately. Argo CD resource hooks put them in the right order inside one sync.

Before the servers: a PreSync Job applies the platform’s MQSC script to the queue manager. The script must be idempotent. Use DEFINE ... REPLACE or a define-then-alter pattern, so running it twice changes nothing. If the Job fails, the sync stops and the integration servers are not touched.

charts/ace-platform/templates/mqsc-presync-job.yaml (Helm template)helm
apiVersion: batch/v1
kind: Job
metadata:
  name: {{ .Values.platform.name }}-mqsc-{{ .Values.generated.mqscHash | trunc 8 }}
  annotations:
    argocd.argoproj.io/hook: PreSync
    argocd.argoproj.io/hook-delete-policy: BeforeHookCreation
spec:
  backoffLimit: 1
  template:
    spec:
      restartPolicy: Never
      containers:
        - name: runmqsc
          image: {{ .Values.shared.mqClientImage }}   # pinned tag
          command: ["/bin/sh", "-c"]
          args:
            - runmqsc -c -e "$QMGR" < /mqsc/platform.mqsc
          env:
            - { name: QMGR, value: {{ .Values.mq.queueManager }} }
            - { name: MQCCDTURL, value: file:///ccdt/ccdt.json }
          volumeMounts:
            - { name: mqsc, mountPath: /mqsc }
            - { name: ccdt, mountPath: /ccdt }
      volumes:
        - { name: mqsc, configMap: { name: {{ .Values.platform.name }}-mqsc } }
        - { name: ccdt, configMap: { name: mq-client-ccdt } }
platforms/orders/config/mq/platform.mqscmqsc
* Idempotent: safe to run on every sync.
DEFINE QLOCAL('ORDERS.REQUEST') MAXDEPTH(50000) DEFPSIST(YES) BOQNAME('ORDERS.BACKOUT') BOTHRESH(3) REPLACE
DEFINE QLOCAL('ORDERS.BACKOUT') MAXDEPTH(50000) DEFPSIST(YES) REPLACE
* Never DELETE here. Removals go through a reviewed, one-off change.

After the servers: a PostSync hook publishes the platform’s API products to the environment’s API Connect catalog. Argo CD runs PostSync hooks only after the sync succeeds and every resource reports healthy. So an API never goes live in front of an integration server that is still starting, or crash-looping. The product files sit in the platform folder, versioned with the BARs they front. Promotion moves both together.

Do not let the MQSC Job delete objects

It is tempting to make the MQ script fully declarative — delete anything not listed. Do not. A queue removed from the file during a refactor would be deleted with its messages on the next sync, in every environment, automatically below production. Additive and idempotent in the hook; removals as an explicit, reviewed change.

Promotion, Rollback, Sync Policy

Promotion is a merge request that copies versions, not files. The promotion job reads the BAR and chart versions from the dev folder of a platform and opens an MR that writes the same versions into the test repository. Then uat. Then prod. The tested build is the deployed build because there is only one build.

Rollback is git revert of the promotion commit. Argo CD sees the previous versions and reconciles. Because BARs are immutable and still in the artefact repository, the previous version is always there to pull.

EnvironmentSyncPrune / self-healWho can merge
devAutomatedYes / yesPlatform CODEOWNERS; CI bot for version bumps
testAutomatedYes / yesPlatform CODEOWNERS
uatAutomatedYes / yesPlatform CODEOWNERS
prodManual, after approved mergeDrift detected and alerted; not auto-correctedMaintainers, with named approver; outside freeze windows

The production freeze window is enforced twice. GitLab blocks merges to the prod environment repo during the window. Argo CD’s AppProject blocks syncs, including manual ones, with a deny window. If one control is misconfigured, the other still holds.

appproject-orders-prod.yaml (excerpt)yaml
apiVersion: argoproj.io/v1alpha1
kind: AppProject
metadata:
  name: orders
spec:
  sourceRepos:
    - https://git.example.com/ops/deploy-prod.git
    - https://git.example.com/platform/integration-charts.git
  destinations:
    - { server: https://kubernetes.default.svc, namespace: int-orders }
  clusterResourceWhitelist: []           # no cluster-scoped kinds
  syncWindows:
    - kind: deny                         # example: no weekend releases
      schedule: '0 18 * * 5'
      duration: 62h
      applications: ['*']
      manualSync: false                  # false = manual syncs are denied too

Compliance as a CI Include

Delivery is only half the story. The other half is what must be true before a version is allowed to move. Do not ask each team to build that. Ship it as shared, versioned CI templates owned by the platform team. A delivery project includes them and sets a handful of variables — five to ten, typically.

TemplateWhat it checksWhen
Compliance-enforced pipelineMandatory jobs injected into every project; cannot be removed by the projectEvery MR
Secret scanCredentials committed to sourceEvery commit and MR
Spectral OpenAPI lintAPI specs against the house ruleset: naming, errors, security schemes, versioningWhen specs change
Pact contract verificationThe provider still honours every consumer contractEvery MR and on merge
ZAP scanBaseline API security scan against a deployed instancePre-production
k6 performancep99 latency against the project’s declared SLOPre-production
.gitlab-ci.yml (a delivery project)yaml
include:
  - project: 'platform/ci-templates'
    ref: v3.4.0                          # a tag: templates are versioned too
    file:
      - templates/secret-scan.yml
      - templates/spectral-lint.yml
      - templates/ace-build.yml       # BAR x.y.z-sha, opens dev MR
      - templates/pact-verify.yml
      - templates/zap-scan.yml
      - templates/k6-performance.yml
# compliance-enforced.yml is attached by the group's compliance
# framework. The project does not include it and cannot remove it.

variables:
  PROJECT_NAME: orders-api
  DOMAIN: payments
  PLATFORM: orders                      # env-repo folder to bump
  PACT_PROVIDER: orders-api
  OPENAPI_GLOB: "api-specs/*.yaml"
  PERFORMANCE_SLO_P99_MS: "800"
  API_REGISTRY_ID: API-PAYMENTS-014

That is the whole file. The pipeline shape, the scanners, their versions and their thresholds live in one place. When the security team tightens a Spectral rule, every project picks it up on the next template release. The minimum bar rises everywhere at once, and nobody files a ticket per team.

Pin the template, then move it on purpose

Including templates from ref: main is the CI equivalent of a latest image. A broken template commit breaks every pipeline in the group at once. Tag template releases. Bump the tag in projects by MR — ideally an automated one — and keep the mandatory compliance jobs in the group-level framework so they cannot be pinned to an old version.

The API Registry

Auditors and partners ask the same question in different forms: every API you publish, to whom, under what SLA. Without a registry, answering takes days of spreadsheets and email. With one, it takes minutes.

The registry does not need a product. A Git repository of YAML files works well: one file per API, validated against a JSON Schema on every commit. CI also checks uniqueness of IDs and that active entries point to something that exists. Retired APIs move to a deprecated/ folder with a sunset date. They are never deleted.

registry/active/API-PAYMENTS-014.yamlyaml
id: API-PAYMENTS-014
name: Orders API
version: 1.8.0
status: active                     # planned | active | deprecated
owner:
  team: payments-integration
  role: product-owner
classification: confidential
consumers:
  - { name: mobile-channel, type: internal }
  - { name: partner-a, type: external, agreement: required }
sla:
  availability: "99.9"
  p99_ms: 800                          # same value the k6 job enforces
spec: api-specs/orders-api.yaml
delivery:
  platform: orders
sunset_date: null

Wire the registry into governance, not beside it. Create a draft entry with status planned when the design is approved at the first review gate. Require the entry to exist and validate before the pre-production review gate will pass. The CI template checks that API_REGISTRY_ID points to a valid entry, and that the SLO the k6 job enforces is the SLO the registry promises. One number, two uses.

Migrating Beside the Old System

Do not rewrite the old push repository in place. Every team depends on it, and changing it under them is the riskiest option on the table. Build the new platform beside it and move platforms one at a time.

  1. Bootstrap once per cluster

    Install the OpenShift GitOps operator and the first Argo CD instance from the console. That is the last cluster-admin action. Everything after is Git.

  2. Prove an empty platform syncs green

    An ApplicationSet over an empty platforms/ folder, AppProjects and namespaces. Boring is the goal.

  3. Pilot with a platform the old system never owned

    A new platform has no ownership conflict. Deploy, upgrade and roll back on dev through MRs only.

  4. Add API products and promotion

    Publish the pilot’s APIs by sync. Then promote the same BAR version from dev to uat unchanged.

  5. Production

    The prod Argo CD, the prod environment repo, approvals and freeze windows. The first prod release goes out by approved MR.

  6. Onboard existing platforms one by one

    Each by agreement with its team, after it is removed from the old pipeline. The old system retires when the last platform leaves — as a separate decision.

Failure Modes

Prune deletes a shared object

If a platform’s chart renders a shared object — a common policy, a pull secret — Argo CD treats it as owned. Remove it from that platform and prune deletes it for everyone. Restrict kinds and namespaces in each AppProject. Render shared objects only from the shared layer. Reference them from platforms by name.

Generated configuration drifts from its sources

Someone fixes a policy directly in the generated zip to unblock a test. It works. The source still holds the old value, and the next regeneration silently reverts the fix. The merge-request check that regenerates and compares is not optional. Fail the pipeline on any difference.

Production drift becomes normal

Production does not self-heal by design, so manual drift persists until someone acts. Route out-of-sync alerts for prod to the on-call channel, not a dashboard. Treat each one as an incident: either the change goes into Git or it is reverted. A prod application that stays out of sync for a week means GitOps has been bypassed.

The operator upgrades underneath you

Operators on automatic approval can roll a new ACE or MQ operator version into every environment at once. That defeats pinned runtimes. Set operator subscriptions to manual approval and move them through environments like any other version.

Production Checklist

  1. Write the defect list first

    Read the current pipeline code and compare it with the cluster. Name each defect. Each rule you adopt should close at least one.

  2. Remove cluster credentials from CI

    Revoke them, do not just stop using them. Then verify CI can still build, publish and open MRs.

  3. One Argo CD and one environment repo per cluster

    No cross-environment credentials. No shared branches.

  4. One Application and one AppProject per platform per environment

    Namespace and kind restrictions in every AppProject. No cluster-scoped kinds for platforms.

  5. Pin everything and make tools enforce it

    Runtime, BAR, chart, images, CI templates, operator subscriptions. The chart fails on floating versions.

  6. Readable, layered configuration with content hashes

    A merge-request check that generated output matches sources, and helm template diffs on every MR.

  7. Hooks for MQ and APIs

    Idempotent, additive MQSC in PreSync. API publishing in PostSync.

  8. Freeze windows enforced in two places

    Merge protection on the prod environment repo and a deny sync window in Argo CD.

  9. Compliance as included templates

    Mandatory jobs in the group compliance framework. Projects set variables, not pipelines.

  10. Registry entry required to pass the pre-production gate

    Schema-validated, with SLA values that the performance job enforces.