Skip to content

Using yq command with the Helm postrender feature - Instead of kustomize

Notifications You must be signed in to change notification settings

abdennour/example-helm-postrender-with-yq

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Overview - Example using helm postrender with yq

Using yq command with the Helm postrender feature to patch YAML rendered by HELM with merge strategy.

Demonstrating that you don't need the complexity of kustomize in order to modify your YAML before being applyed by HELM. But just the portable CLI yq

Prerequisites

Test it

  • Check content of test.sh
  • Run it and validate it works bash test.sh

How we start

  1. Scaffolding a helm chart helm create my-chart

  2. Create the patch file patch.yaml which includes some labels to be patched to all resources. If you want to select/filter resources by kind (for example), you may need to check this example

  3. Creating the postrender script which calls yq command

  4. Writing the test.sh script which includes the testing command helm template. As per helm docs, you can use --post-render not only with helm template but also with helm install as well helm upgrade

About

Using yq command with the Helm postrender feature - Instead of kustomize

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published