The repo supports three environments: dev, staging, and prod. Each environment uses the same components but with different resource allocations and configuration.
| Aspect | Dev | Staging | Prod |
|---|---|---|---|
| Purpose | Local development | Pre-production testing | Production workloads |
| Replicas | Minimal (1) | Moderate (1-2) | High availability (2-3) |
| Resources | Low requests/limits | Moderate | Substantial |
| Vault mode | Dev (in-memory) | Standalone (persistent) | HA with Raft |
| Prometheus retention | 2h | 4h | 6h |
| Trivy concurrent scans | 2 | 3 | 5 |
Each component uses two values files applied in order:
values/base.yaml— shared defaults (features, integrations, non-resource settings)values/<env>.yaml— environment-specific overrides (replicas, resources, feature flags)
Environment values take precedence. Helm performs a deep merge, so environment files only need to specify the keys they override.
values/base.yaml:
external-secrets:
installCRDs: true
webhook:
replicaCount: 1
certController:
replicaCount: 1values/prod.yaml:
external-secrets:
replicaCount: 3
webhook:
replicaCount: 3
certController:
replicaCount: 3
resources:
requests:
cpu: 100m
memory: 128MiResult for prod: CRDs are installed (from base), 3 replicas with explicit resources (from prod).
Resources scale across environments following a consistent pattern:
| Dev | Staging | Prod | |
|---|---|---|---|
| CPU requests | 10-50m | 50-200m | 100-500m |
| Memory requests | 32-128Mi | 64-512Mi | 128Mi-1Gi |
| CPU limits | 100-200m | 100-500m | 250m-1000m |
| Memory limits | 128-256Mi | 256Mi-1Gi | 512Mi-2Gi |
Dev environments use minimal resources suitable for local clusters (kind, minikube). Production allocates enough for reliability under load.
Component defaults (namespace, sync wave, syncOptions, etc.) are defined in apps/values.yaml. The environment files in apps/values/ only need to set the environment name:
# apps/values/dev.yaml
environment: devAll components are enabled by default. To disable a component for a specific environment, override its enabled flag:
# apps/values/dev.yaml
environment: dev
components:
trivy-operator:
enabled: falseHelm performs a deep merge, so only the overridden properties change — the rest inherits from apps/values.yaml.
- Create
apps/values/<env>.yamlwithenvironment: <env> - Create
values/<env>.yamlin each component undercomponents/ - Create
secrets.<env>.enc.yamlwith encrypted credentials - Bootstrap with
./cluster-bootstrap-cli/cluster-bootstrap-cli bootstrap <env>