Files
cozystack/packages/core/installer/values.yaml
Myasnikov Daniil cf2698e0cf feat(operator): expose Install/Upgrade timeouts and MaxHistory as flags
The HelmRelease generation in package_reconciler hardcoded three values
that have caused recurring pain:

- Install.Timeout = 10m (line 214)
- Upgrade.Timeout = 10m (line 220)
- MaxHistory = unset (Helm default 5)

The 10m timeout in particular contradicts the per-Application timeout
work done in `pkg/config/config.go` and
`pkg/registry/apps/application/rest.go` (commit 7b146cbe), which lets
individual Applications override the install/upgrade timeout via
annotation. The PackageSource side had no equivalent — etcd works around
it by hand-rolling its HR YAML in `packages/apps/tenant/templates/etcd.yaml`
to set a 30m timeout, harbor has had multiple commits chasing the same
problem from the other side. This closes that gap.

New operator flags (each maps to a chart value with empty default;
operator uses its own default when value is empty):

- `--helmrelease-install-timeout` (default 10m) → Spec.Install.Timeout
- `--helmrelease-upgrade-timeout` (default 10m) → Spec.Upgrade.Timeout
- `--helmrelease-max-history` (default 5)        → Spec.MaxHistory

Production behaviour unchanged. E2E and edge cases (cert rotation,
slow-installing charts) can override per-cluster without modifying
chart manifests.

Per-component overrides on `ComponentInstall` (mirroring the existing
`UpgradeCRDs` pattern) would be a strictly better fix for charts like
etcd that need an outlier timeout — left as a deliberate followup since
it touches the Package CR API.

Signed-off-by: Myasnikov Daniil <myasnikovdaniil2001@gmail.com>
2026-04-28 12:44:19 +05:00

35 lines
2.0 KiB
YAML

cozystackOperator:
# Deployment variant: talos, generic, hosted
variant: talos
image: ghcr.io/cozystack/cozystack/cozystack-operator:v1.3.0@sha256:62574f12486bb40c901cf5ed484cca264405ce5810196d86555cbb27cce1ba48
platformSourceUrl: 'oci://ghcr.io/cozystack/cozystack/cozystack-packages'
platformSourceRef: 'digest=sha256:a0b9ef938446b3132d3d22ad2262beb1027c48c9037b6c2346fdc2f19acd3036'
# When non-empty, overrides the operator's --helmrelease-interval flag
# (operator default: 5m). E2E sets this to 30s; production should leave empty.
helmReleaseInterval: ""
# When non-empty, overrides the operator's --helmrelease-retry-interval flag
# (operator default: 30s). Controls how fast failed install/upgrade attempts
# are retried. Decoupled from helmReleaseInterval (healthy reconcile cadence).
helmReleaseRetryInterval: ""
# When non-empty, overrides the operator's --helmrelease-install-timeout flag
# (operator default: 10m). Bounds individual k8s operations (job/hook/wait)
# during Helm install. Charts with long-running install hooks may need longer.
helmReleaseInstallTimeout: ""
# When non-empty, overrides the operator's --helmrelease-upgrade-timeout flag
# (operator default: 10m). Same semantics as helmReleaseInstallTimeout, for
# the Helm upgrade action.
helmReleaseUpgradeTimeout: ""
# When non-empty, overrides the operator's --helmrelease-max-history flag
# (operator default: 5). Number of release revisions Helm keeps per HR.
# Use 0 for unlimited; lower values reduce Secret accumulation in test clusters.
helmReleaseMaxHistory: ""
# Generic variant configuration (only used when cozystackOperator.variant=generic)
cozystack:
# Kubernetes API server host (IP only, no protocol/port)
# Must be the INTERNAL IP of the control-plane node
# (the IP visible on the node's network interface, not a public/NAT IP)
# Used by the operator and networking components (cilium, kube-ovn)
apiServerHost: ""
# Kubernetes API server port
apiServerPort: "6443"