Repository navigation
Shrink the chart template helpers without changing output - #377
Merged
Merged
Conversation
Inline helpers that have one caller, drop internal `required` guards, and merge the validators into one `logfire.validateConfig` that keeps their order and messages. Wrap the `_helpers*.tpl` files at 100 columns; the manifests keep one line per entry. Rendered manifests do not change. Bump the chart to 0.15.4-rc.5.
… ifs Move the trusted CA, dev Postgres wait and Absurd queue wait containers into `logfire.initContainers`, their only caller. Their output keeps the same whitespace, so the post-deploy migrations Job name does not change. Split the one-line conditionals whose output does not depend on staying on one line.
The refactor read some values with multi-key `dig`, which fails on a null or non-map step, and dropped a few fallbacks. Restore main's handling: - `<service>.image`, `.service` and `.securityContext` set to null fall back to the chart defaults again. - The RustFS bucket reads `rustfs.bucket` only when the URI names no bucket. - `otel_collector.prometheus: false` turns the exporter off again. - Dex `connectors` and `staticClients` keyed by name render as lists again. Pin each shape in resource_shape_test.yaml.
- Dex `connectors` and `staticClients`, `groupOrganizationMapping`, `project_roles` and `hooksAnnotations` set to false render as empty again. - `auth.passkeys`, `auth.passwordLogin` and `auth.passwordlessEmailSignup` set to "" still render their env var, as on main. - A trusted CA bundle `key` set to a falsy value renders as given, as on main. Pin the Dex and group mapping shapes in resource_shape_test.yaml.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Internal cleanup of the chart templates. Rendered manifests do not change.
logfire.autoscalercall per workload, and thevalidate.*helpers become onelogfire.validateConfigthat keeps their order and messages.requiredguards on helper arguments are gone. Every check that a values change can trigger keeps its message, and the| default dictreads that--reuse-valuesupgrades rely on stay._helpers*.tplfiles wrap at 100 columns. The manifests keep one line per entry._helpers.tpl(2,369 → 1,780) and_helpers-validation.tpl(588 → 341).Rendering every unit-test case, the values fixtures and about 50 extra value sets with
helm templategives the same manifests asmain, apart from random secrets. That includes the config checksums and the post-deploy migration Job name, which hash rendered text. A second run sets every values key to each ofnull,false,"",0,{}and[], on top ofvalues.prod.yamland on top of a values file with most features on (about 25,000 cases). Every set that renders onmainrenders the same on this branch.Upgrade notes
None.