Flux in depth
Example: bootstrapping a fleet with Flux
Example: a hypothetical company runs staging and production clusters in two regions. An engineer runs flux bootstrap against the configuration repository for each cluster. Bootstrap installs the Flux controllers and commits their manifests to a cluster-specific path, so Flux then manages its own upgrades through Git. Each cluster path contains Kustomizations: one for infrastructure (ingress, cert-manager, monitoring), one for application workloads that dependsOn the infrastructure Kustomization, so applications wait until their dependencies are healthy. Cluster-specific values such as region and domain are injected through post-build variable substitution from a ConfigMap. Secrets are stored in Git encrypted with SOPS and decrypted by the kustomize-controller using a key from the cloud key management service.
Key building blocks
- GitRepository, OCIRepository, HelmRepository, Bucket: sources that Flux fetches and verifies, including signature verification for Git commits and OCI artifacts signed with Cosign.
- Kustomization: applies a path from a source on an interval, with prune, health checks, timeouts and dependencies.
- HelmRelease: declares a Helm chart, version and values; the helm-controller installs, upgrades, tests and can remediate failed releases.
- ImageRepository, ImagePolicy, ImageUpdateAutomation: scan registries and commit new image tags to Git according to a policy such as semantic version ranges.
- Alerts and Providers: send reconciliation events to Slack, Teams, Git commit statuses and other targets.
Multi-tenancy and security
Flux supports tenant isolation by having each tenant's Kustomizations and HelmReleases run under a specific Kubernetes service account in the tenant's namespace, so a tenant can only create what that service account's RBAC allows. Platform teams keep cluster-wide resources in a separate path that tenants cannot modify. Because each cluster pulls its own state, no central system needs credentials to every cluster, which narrows the blast radius if one environment is compromised.
Operating and measuring Flux
The flux CLI shows reconciliation status (flux get), forces a sync (flux reconcile), pauses automation during incidents (flux suspend) and previews changes (flux diff kustomization). Flux controllers expose Prometheus metrics and Kubernetes events, so you can alert on Kustomizations or HelmReleases that are not Ready, and on reconciliation duration. Track time from merge to Ready as part of change lead time in DORA metrics. For progressive delivery, Flagger, a sibling Flux project, automates canary and blue-green rollouts.
Common mistakes
- One giant Kustomization for the whole cluster, so one broken manifest blocks everything.
- No dependsOn ordering, causing applications to fail while custom resource definitions are still installing.
- Suspending reconciliation during an incident and forgetting to resume it.
- Very short intervals on many objects, which adds load on Git hosts and the API server; use webhooks for fast feedback instead.
Flux implements GitOps using Kustomize and Helm; Argo CD is the main alternative. We help teams choose, set up and migrate in our GitOps service.