Skip to content

Commit

Permalink
add release namespace to the helm templates
Browse files Browse the repository at this point in the history
  • Loading branch information
Skarlso committed Jan 22, 2024
1 parent 8e8a804 commit c4c9d5c
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 0 deletions.
3 changes: 3 additions & 0 deletions docs/release_notes/v0.3.10.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# Release v0.3.10

Add `{{ Release.Namespace }}` to the templates to use the proper release namespace.
15 changes: 15 additions & 0 deletions hack/create_helm_chart.sh
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,21 @@ create_helm_chart() {
mv ${input} ../${CONTROLLER}/templates/${TYPE}_${FILENAME}.yaml
fi
done

case "${1}" in
"helm" )
#mac
find "../${CONTROLLER}/templates" -type f -name '*.yaml' -exec sed -i "" "s/namespace: .*/namespace: {{ .Release.Namespace }}/g" {} \;
;;
"output" )
#ubuntu
find "../${CONTROLLER}/templates" -type f -name '*.yaml' -exec sed -i "s/namespace: .*/namespace: {{ .Release.Namespace }}/g" {} \;
;;
* )
exit
;;
esac

cd ..
rm -rf helm_temp
}
Expand Down

0 comments on commit c4c9d5c

Please sign in to comment.