{"id":17710180,"url":"https://github.com/hendrikmaus/helm-templexer","last_synced_at":"2025-05-12T13:27:13.266Z","repository":{"id":46710839,"uuid":"281746486","full_name":"hendrikmaus/helm-templexer","owner":"hendrikmaus","description":"Render Helm charts for multiple environments using explicit configuration.","archived":false,"fork":false,"pushed_at":"2023-05-09T08:20:57.000Z","size":207,"stargazers_count":24,"open_issues_count":11,"forks_count":3,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-05-06T23:05:23.520Z","etag":null,"topics":["helm","kubernetes","rust"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/hendrikmaus.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":"CODEOWNERS","security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-07-22T17:52:56.000Z","updated_at":"2025-02-08T03:34:22.000Z","dependencies_parsed_at":"2024-10-25T08:19:38.641Z","dependency_job_id":"28dda37a-7b78-45e6-9303-d60110c3c3bb","html_url":"https://github.com/hendrikmaus/helm-templexer","commit_stats":null,"previous_names":[],"tags_count":24,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hendrikmaus%2Fhelm-templexer","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hendrikmaus%2Fhelm-templexer/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hendrikmaus%2Fhelm-templexer/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hendrikmaus%2Fhelm-templexer/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/hendrikmaus","download_url":"https://codeload.github.com/hendrikmaus/helm-templexer/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253747059,"owners_count":21957683,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["helm","kubernetes","rust"],"created_at":"2024-10-25T06:22:32.000Z","updated_at":"2025-05-12T13:27:13.240Z","avatar_url":"https://github.com/hendrikmaus.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ⎈ Helm Templexer\n\n[![crates.io](https://img.shields.io/crates/v/helm-templexer.svg)](https://crates.io/crates/helm-templexer)\n\nRender Helm charts for multiple environments with _explicit config_ while keeping the overhead at ease.\n\n\u003e The `helm-templexer` wraps **Helm v3+**, please ensure that it is installed and in the `PATH`.\n\n```shell\ncat \u003e my-app.yaml \u003c\u003cEOF\nversion: v2\nchart: tests/data/nginx-chart\nrelease_name: my-app\noutput_path: manifests\ndeployments:\n  - name: edge\n  - name: stage\n  - name: prod\nEOF\n\nhelm-templexer render my-app.yaml\n```\n\nOutcome:\n\n```text\n❯ exa -T manifests\nmanifests\n├── edge\n│  └── my-app\n│     └── manifest.yaml\n├── prod\n│  └── my-app\n│     └── manifest.yaml\n└── stage\n   └── my-app\n      └── manifest.yaml\n```\n\n## Configuration\n\nConfiguration can be provided as YAML format.\n\nAll paths are evaluated relative to the configuration file during execution.\n\n\u003e Looking for schema `v1`? Please see [helm-templexer 1.x](https://github.com/hendrikmaus/helm-templexer/tree/v1).\n\n| **Parameter**        | **Description**                                                                                                                                                                                                                                                                    | **Condition** | **Default** | **Example**                          |\n|----------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|:-------------:|-------------|--------------------------------------|\n| `version`            | Schema version to use                                                                                                                                                                                                                                                              |  **required** |             | `\"v2\"`                               |\n| `enabled`            | Whether to render deployments or not                                                                                                                                                                                                                                               |    optional   | `true`      |                                      |\n| `chart`              | Path to the chart to render                                                                                                                                                                                                                                                        |  **required** |             | `\"path/to/some-chart\"`               |\n| `namespace`          | Namespace to pass on to `helm`; when omitted, no namespace is passed                                                                                                                                                                                                               |    optional   | `\"\"`        |                                      |\n| `release_name`       | Release name to pass to `helm`                                                                                                                                                                                                                                                     |  **required** |             | `\"some-release\"`                     |\n| `output_path`        | Base path to use for writing the manifests to disk.\u003cbr\u003e\u003cbr\u003eThe fully-qualified output path is built as follows (`config` refers to the top-level):\u003cbr\u003e`config.output_path/deployment.name/\u003c[config/deployment].release_name\u003e/manifest.yaml`                                                      |  **required** |             |                                      |\n| `additional_options` | Pass additional options to `helm template`; you can use all supported options of the tool.\u003cbr\u003e\u003cbr\u003eCommon use case: use `--set-string` to provide a container tag to use.\u003cbr\u003eThis can be achieved by modifying the configuration file in your build pipeline using mikefarah/yq |    optional   | `[]`        | `[\"--set-string image.tag=42\"]`      |\n| `values`             | A list of base value files which are passed to each `helm template` call.\u003cbr\u003eThis is commonly used to provide a sane base config.                                                                                                                                                  |    optional   | `[]`        |                                      |\n| `deployments`        | The list of deployments to render.                                                                                                                                                                                                                                                 |  **required** |             | `[[deployments]]`\u003cbr\u003e`name = \"edge\"` |\n\nDeployments can override several top-level fields:\n\n| **Parameter**        | **Description**                                                    | **Condition** | **Default** | **Example**    |\n|----------------------|--------------------------------------------------------------------|---------------|-------------|----------------|\n| `name`               | Name of the deployment; only used in the output path               | **required**  |             | `\"edge-eu-w4\"` |\n| `enabled`            | Allows for disabling individual deployments                        | optional      | `true`      |                |\n| `release_name`       | Override the release name                                          | optional      | `\"\"`        |                |\n| `additional_options` | Additional options, as seen above, but specific to this deployment | optional      | `[]`        |                |\n| `values`             | Value files to use for this deployment                             | optional      | `[]`        |                |\n\n## Additional Options to The Render Command\n\n### Extending The `helm template` Call\n\nUse `--additional-options` to pass data to the underlying `helm template` call. Beware that these additional options get added to *every* call, i.e. to each deployment.\n\nA common use case we found was to provide the container tag:\n\n```shell\nhelm-templexer render --additional-options=\"--set-string image.tag=${revision}\" my-app.yaml\n```\n\n### Render a Subset of Deployments\n\nUse `--filter` to render a specific deployment. Example: To render only the `prod`, pass the regex to the filter option.\n\n```shell\nhelm-templexer render --filter=\"prod\" my-app.yaml\n```\n\n### Update Helm Dependencies Before Rendering\n\nUse `--update-dependencies` to run `helm dependencies update` *once* before starting to render the deployments.\n\n```shell\nhelm-templexer render --update-dependencies my-app.yaml\n```\n\n### Pipe Manifest Output Through Tool(s) Before Writing to Disk\n\nUse `--pipe` to pass the manifest output through a tool or set of tools before writing to a file.\n\nPlease mind that this option **requires** an equal sign (`=`), i.e. `--pipe=\"\u003ccommand\u003e\".\n\n```shell\nhelm-templexer render --pipe=\"kbld -f -\" my-app.yaml\n```\n\nYou can define the argument multiple times; the commands will be added in order of appearance to the final command.\n\n```shell\nhelm-templexer render --pipe=\"kbld -f -\" --pipe=\"tee /dev/stdout\" my-app.yaml\n```\n\nIf anything unexpected happens, you can use `-v`, `-vv` and `-vvv` to increase the log level and see the underlying command.\n\n## Installation\n\n### Docker\n\n```shell\n# create the directory where helm-templexer will render to\nmkdir -p tests/data/manifests\n\n# let helm-templexer's user id (1001) own the directory\nsudo chown -R 1001 tests/data/manifests\n\n# pull and run the image\ndocker pull ghcr.io/hendrikmaus/helm-templexer\ndocker run --rm --volume $(pwd):/srv --workdir /srv/tests/data ghcr.io/hendrikmaus/helm-templexer render config_example.yaml \n```\n\nInclude `helm-templexer` in your `Dockerfile`:\n\n```Dockerfile\nFROM ghcr.io/hendrikmaus/helm-templexer AS helm-templexer-provider\nCOPY --from=helm-templexer-provider /usr/bin/helm-templexer /usr/bin\nCOPY --from=helm-templexer-provider /usr/bin/helm /usr/bin\n```\n\n### Pre-compiled Binary\n\nPlease set/replace `$TARGET` and `$VERSION` accordingly.\n\n```shell\nwget https://github.com/hendrikmaus/helm-templexer/releases/download/v$VERSION/helm-templexer-$VERSION-$TARGET.tar.gz -O - | tar xz \u0026\u0026 mv helm-templexer /usr/bin/helm-templexer\n```\n\nFor example `VERSION=2.0.0` and `TARGET=aarch64-apple-darwin`\n\nThe `mv` to `/usr/bin` might require `sudo`.\n\n#### Validate Against Checksum\n\nTo validate the downloaded **archive** against the checksum:\n\n```shell\nwget https://github.com/hendrikmaus/helm-templexer/releases/download/v$VERSION/helm-templexer-$VERSION-$TARGET.tar.gz\necho \"$(wget https://github.com/hendrikmaus/helm-templexer/releases/download/v$VERSION/helm-templexer-$VERSION-$TARGET.tar.gz.sha256 -O -) helm-templexer-$VERSION-$TARGET.tar.gz\" | sha256sum --check --strict --status\n```\n\n### Homebrew\n\n```shell\nbrew tap hendrikmaus/tap\nbrew install helm-templexer\n```\n\n### Cargo Install\n\nHelm Templexer is written in [Rust](http://www.rust-lang.org/). You will need `rustc` version 1.35.0 or higher. The recommended way to install Rust is from the official download page. Once you have it set up, a simple `make install` will compile `helm-templexer` and install it into `$HOME/.cargo/bin`.\n\nIf you’re using a recent version of Cargo (0.5.0 or higher), you can use the `cargo install` command:\n\n```shell\ncargo install helm-templexer\n```\n\nCargo will build the binary and place it in `$HOME/.cargo/bin` (this location can be overridden by setting the --root option).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhendrikmaus%2Fhelm-templexer","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhendrikmaus%2Fhelm-templexer","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhendrikmaus%2Fhelm-templexer/lists"}