Skip to content

fix(validate-k8s-manifests): properly handle env & additional region values files#126

Merged
ahoneiser merged 1 commit intomainfrom
fix-k8s-manifest-validation
Jan 29, 2026
Merged

fix(validate-k8s-manifests): properly handle env & additional region values files#126
ahoneiser merged 1 commit intomainfrom
fix-k8s-manifest-validation

Conversation

@ahoneiser
Copy link
Contributor

@ahoneiser ahoneiser commented Jan 28, 2026

The validate-k8s-manifests workflow does not respect region specific
values files as it should.

We support 3 "types" of naming patterns for values files at the moment:

  • GPA
    Pattern: %domain%.values.(yaml|yml)
    e.g.: webservices.values.yaml

  • tenant (env in primary region)
    Pattern: values(-ent)?-[[:alnum:]]+.(yaml|yml)
    e.g.: values-prod.yaml

  • Tenant (env in additional region)
    Pattern: values(-ent)?-[[:alnum:]]+((-[[:alnum:]]+){2})?.(yaml|yml)
    e.g.: values-prod-europe-west1.yaml

We generally consider case 3 to be an additional values file that's
merged on top of case 2's values file (e.g. in ArgoCD). This change
renders case 3 to an extra artifact to make validation work as expected.

@ahoneiser ahoneiser self-assigned this Jan 28, 2026
@ahoneiser ahoneiser force-pushed the fix-k8s-manifest-validation branch 3 times, most recently from cbddf51 to 50fcdc1 Compare January 29, 2026 15:04
Copy link
Contributor

@grahamalama grahamalama left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

IIUC:

  • The outer while loop looks at all values files that aren't values.{yml,yaml} (for chart types 1, 2, and 3)
  • in that loop, we render charts for types 1 and 2
  • in the inner while loop (while read region_values_file;), we render additional charts for the regional overrides (type 3)

…values files

The validate-k8s-manifests workflow does not respect region specific
values files as it should.

We support 3 "types" of naming patterns for values files at the moment:

* GPA
  Pattern: %domain%\.values\.(yaml|yml)
  e.g.: webservices.values.yaml

* tenant (env in primary region)
  Pattern: values(-ent)?-[[:alnum:]]+\.(yaml|yml)
  e.g.: values-prod.yaml

* Tenant (env in additional region)
  Pattern: values(-ent)?-[[:alnum:]]+((-[[:alnum:]]+){2})?\.(yaml|yml)
  e.g.: values-prod-europe-west1.yaml

We generally consider case 3 to be an additional values file that's
merged on top of case 2's values file (e.g. in ArgoCD). This change
renders case 3 to an extra artifact to make validation work as expected.
@ahoneiser ahoneiser force-pushed the fix-k8s-manifest-validation branch from 50fcdc1 to e703171 Compare January 29, 2026 16:03
@ahoneiser ahoneiser merged commit 4784cb7 into main Jan 29, 2026
3 checks passed
@ahoneiser ahoneiser deleted the fix-k8s-manifest-validation branch January 29, 2026 17:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants