Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(templates): ensure named templates follow helm best practices #160

Merged
merged 6 commits into from
Jun 27, 2024

Conversation

tthvo
Copy link
Member

@tthvo tthvo commented Jun 27, 2024

Related to #110
Related to #159 (some are required for helm unittest to function, i.e. point [1] and [2])

What's changed

Changes that follow best practices:

  • Renamed files ending with .tpl to have underscore prefix _. [1]
  • Renamed named templates with chart name (i.e. named templates are global so its best practice to prefix with chart name to avoid collision in case sub-charts are available).
  • Added comments to named templates if missing.

Changes that might impact chart installation:

  • Removed duplicate securityContext field for storage container. [2]
  • Fixed incorrect indentation for securityContext field for proxy containers.
  • Fixed nil pointer exception when generating NOTEs.txt with ingress enabled.

References

@tthvo tthvo added fix chore Refactor, rename, cleanup, etc. safe-to-test labels Jun 27, 2024
@tthvo tthvo requested review from andrewazores, ebaron and a team June 27, 2024 00:07
Copy link
Member

@ebaron ebaron left a comment

Choose a reason for hiding this comment

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

Thanks @tthvo! Seems like there are some pretty important bugfixes here. You think we should do a last minute backport to 3.0?

@andrewazores
Copy link
Member

Seems worthwhile.

@ebaron ebaron merged commit 8115c82 into cryostatio:main Jun 27, 2024
6 checks passed
mergify bot pushed a commit that referenced this pull request Jun 27, 2024
…160)

* chore(proxy): prefix partial templates with underscore

* chore(templates): prefex named template with chart name

* chore(deploy): remove duplicate securityContext field and blank space

* chore(templates): add comments for named templates

* fix(notes): fix nil pointer exceptions

* fix: non-empty tls should show https url

(cherry picked from commit 8115c82)
andrewazores pushed a commit that referenced this pull request Jun 27, 2024
…160) (#163)

* chore(proxy): prefix partial templates with underscore

* chore(templates): prefex named template with chart name

* chore(deploy): remove duplicate securityContext field and blank space

* chore(templates): add comments for named templates

* fix(notes): fix nil pointer exceptions

* fix: non-empty tls should show https url

(cherry picked from commit 8115c82)

Co-authored-by: Thuan Vo <[email protected]>
@tthvo tthvo deleted the helm-practice branch June 27, 2024 18:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport chore Refactor, rename, cleanup, etc. fix safe-to-test
Projects
Status: Done
Status: Done
Development

Successfully merging this pull request may close these issues.

3 participants