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

feat: add git chart downloader #42

Open
wants to merge 5 commits into
base: master
Choose a base branch
from
Open

Conversation

mgoltzsche
Copy link
Owner

@mgoltzsche mgoltzsche commented Oct 12, 2022

This is meant to be compatible with the helm-git plugin.

TL;DR:
The plugin has been reimplemented here since it relies on helm commands khelm does not support and since it doesn't build git charts as effective as khelm. khelm uses go-git to keep the image small and self-contained: the git binary would increase the container image size by 15m while using go-git increases the size by 3m only. However currently go-git does not support sparse checkouts.

@mgoltzsche mgoltzsche force-pushed the helm-git-support branch 13 times, most recently from 8868a25 to ff92b7a Compare October 17, 2022 01:39
@mgoltzsche mgoltzsche changed the title feat: add git getter (chart downloader) feat: add git chart downloader Oct 17, 2022
@mgoltzsche mgoltzsche force-pushed the helm-git-support branch 7 times, most recently from 2450565 to 0d1b29e Compare October 17, 2022 22:50
@mgoltzsche mgoltzsche force-pushed the helm-git-support branch 3 times, most recently from 57cfbb8 to 96a4ed3 Compare October 30, 2022 18:24
This is meant to be compatible with the [helm-git](https://github.com/aslafy-z/helm-git) plugin.
The plugin has been reimplemented here since it relies on unsupported helm commands and since it doesn't build git charts as effective as khelm.
khelm uses go-git to keep the image small and self-contained: the git binary would increase the container image size by 15m while using go-git increases the size by 3m only.
However currently [go-git does not support sparse checkouts](go-git/go-git#90).
Use the credentials configured within repositories.yaml also for git+https urls.
To avoid reloading the config, move repository-related code into a separate package.
Also, disable git getter by default and add IsUntrustedRepository method
back to helm package for backward-compatibility and convenience.
@mgoltzsche
Copy link
Owner Author

mgoltzsche commented Jan 19, 2023

I needed this for a previous approach but I don't need it anymore. I am not sure whether it should still be merged since it adds more features to the binary that may be rarely needed but that increase the binary size.

Please vote with thumbs up/down whether or not you want this PR to be merged.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant