Skip to content

Add CALICO_API_GROUP env var injection via apigroup package#4576

Merged
caseydavenport merged 2 commits intotigera:masterfrom
caseydavenport:casey-migration-apigroup
Mar 24, 2026
Merged

Add CALICO_API_GROUP env var injection via apigroup package#4576
caseydavenport merged 2 commits intotigera:masterfrom
caseydavenport:casey-migration-apigroup

Conversation

@caseydavenport
Copy link
Member

Introduce pkg/apigroup to track the active CRD API group and inject CALICO_API_GROUP into all workload containers via the component handler. This tells components whether to use projectcalico.org/v3 or the legacy crd.projectcalico.org/v1 API group.

At startup, UseV3CRDS() determines the active group. If v3, apigroup.Set(apigroup.V3) is called, and every subsequent CreateOrUpdateOrDelete call injects the env var into all Deployment/DaemonSet/StatefulSet/Job/CronJob containers.

Stacked on #4575 -- merge that first.

Introduce pkg/apigroup to track the active CRD API group and inject
CALICO_API_GROUP into all workload containers via the component handler.
This tells components whether to use projectcalico.org/v3 or the legacy
crd.projectcalico.org/v1 API group.
@caseydavenport caseydavenport force-pushed the casey-migration-apigroup branch from 94edd6a to 4081174 Compare March 23, 2026 17:11
@caseydavenport caseydavenport merged commit 7b38090 into tigera:master Mar 24, 2026
6 checks passed
@caseydavenport caseydavenport deleted the casey-migration-apigroup branch March 24, 2026 04:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants