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

HMC chart installation fails with "Unable to continue with install: CustomResourceDefinition "certificaterequests.cert-manager.io" in namespace "" exists and cannot be imported" #261

Closed
squizzi opened this issue Sep 4, 2024 · 1 comment
Labels
bug Something isn't working invalid This doesn't seem right

Comments

@squizzi
Copy link
Contributor

squizzi commented Sep 4, 2024

#193 introduced an issue when installing the HMC chart:

Error: INSTALLATION FAILED: rendered manifests contain a resource that already exists. Unable to continue with install: CustomResourceDefinition "certificaterequests.cert-manager.io" in namespace "" exists and cannot be imported into the current release: invalid ownership metadata; annotation validation error: key "meta.helm.sh/release-name" must equal "hmc": current value is "cert-manager"; annotation validation error: key "meta.helm.sh/release-namespace" must equal "default": current value is "cert-manager"

Currently we have the following settings for the cert-manager subchart in our chart:

cert-manager:
  enabled: true
  crds:
    enabled: true <---

Setting that to false allows the chart to install without issues.

Maybe instead of relying on the chart to manage the cert-manager CRD we should use a finalizer in HMC to perform the deletion?

@squizzi squizzi added the bug Something isn't working label Sep 4, 2024
@Kshatrix
Copy link
Collaborator

Kshatrix commented Sep 5, 2024

What changed in #193 is that cert-manager CRDs are now removed when HMC is uninstalled. If you manage your own cert-manager, you can disable it with cert-manager.enabled=false. If, for some reason, you already have CRDs created, you can disable CRD creation as well. By default, we assume there's no cert-manager present in the cluster and install both cert-manager and its CRDs.

@Kshatrix Kshatrix closed this as completed Sep 5, 2024
@DinaBelova DinaBelova added the invalid This doesn't seem right label Sep 13, 2024
@alex-shl alex-shl added this to K0rdent Jan 3, 2025
@alex-shl alex-shl moved this to Done in K0rdent Jan 3, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working invalid This doesn't seem right
Projects
Status: Done
Development

No branches or pull requests

3 participants