-
Notifications
You must be signed in to change notification settings - Fork 93
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: allow migrate from HelmChart v1beta1 to v1beta2 if Helm --take-ownership is set #5046
base: main
Are you sure you want to change the base?
Conversation
This needs to be merged alongside updating Helm to either use the version with |
I've updated the PR with fetching from Helm PR that supports |
edda4b7
to
c0daf44
Compare
deploy/melange.yaml.tmpl
Outdated
|
||
pipeline: | ||
- runs: | | ||
set -x | ||
export DESTDIR="${{targets.destdir}}" | ||
mkdir -p "${DESTDIR}" | ||
|
||
# Build Helm from PR 13439 | ||
# to be removed later when latest Helm supports --take-ownership flag | ||
git clone --depth 1 https://github.com/helm/helm.git |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should use melange git-checkout
like this: https://github.com/wolfi-dev/os/blob/9a2344577f49c44a869a12f186cb6a11318fe4fd/checksec.yaml#L25-L34
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
and use a specific commit
@@ -59,6 +72,5 @@ pipeline: | |||
mv bin/kotsadm "${DESTDIR}/kotsadm" | |||
mv bin/kots "${DESTDIR}/kots" | |||
|
|||
ln -s /usr/bin/helm ${DESTDIR}/usr/local/bin/helm |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you'll also need to remove the helm binary from the apko file: https://github.com/replicatedhq/kots/blob/main/deploy/apko.yaml.tmpl#L16
deploy/melange.yaml.tmpl
Outdated
git checkout pr-13439 | ||
make | ||
chmod a+x bin/helm | ||
mv bin/helm "${DESTDIR}/usr/local/bin/" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you need to run mkdir -p ${DESTDIR}/usr/local/bin/
first. which is why CI is failing
c0daf44
to
2ebd087
Compare
Many thanks @sgalsaleh! I have made the requested changes accordingly and notice the Melange and Apko actions completed successfully. Please let me know how it goes. |
What this PR does / why we need it:
We currently don't allow migration from existing Helm installation of
v1beta1
withuseHelmInstall: false
to Helmv1beta2
.As Helm CLI will soon support
--take-ownership
flag, this will be possible.This PR allows the application pull for Helm chart with same name in
v1beta2
, as long as there is--take-ownership
flag in Helm additional upgrade flags.Demo: https://www.loom.com/share/db17e620509843d884fbcf98605daaed?t=281
If no
--take-ownership
flag, pull will fail during update checksWhich issue(s) this PR fixes:
Story: https://app.shortcut.com/replicated/story/117029/add-keep-annotation-to-kots
Does this PR require a test?
NONE
Does this PR require a release note?
We will need a release note later when upstream Helm CLI supports
--take-ownership
flag.Does this PR require documentation?
Current docs will have to be updated after the change is merged and upstream Helm CLI supports
--take-ownership
flag