gitpod-io / replicated

Install Gitpod with Replicated
https://kots.io/vendor
0 stars 0 forks source link

Installation fails when there is already a cert-manager installed in the cluster #2

Open corneliusludmann opened 2 years ago

corneliusludmann commented 2 years ago

Error:

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

Verson: 0.0.1 Release Sequence 162

corneliusludmann commented 2 years ago
$ helm ls -aA
NAME            NAMESPACE       REVISION        UPDATED                                 STATUS        CHART                   APP VERSION
cert-manager    cert-manager    1               2022-02-18 15:14:23.025994222 +0000 UTC deployed      cert-manager-v1.7.1     v1.7.1    
mrsimonemms commented 2 years ago

I think this is due to cert-manager already being installed to the cluster when the Replicated installation happens.

1. Solution to unblock you today

Run helm un -n cert-manager cert-manager to remove the Helm installation

2. Fix we need to code in

We need to apply a when annotation to the manifest. I have no idea if this is possible, so will raise as an issue in my next sync with @BarryWilliams if I can't find a way to do this

corneliusludmann commented 2 years ago

I think this is due to cert-manager already being installed to the cluster when the Replicated installation happens.

By whom? Is it installed by Replicated already? If so, can we just trust that this is already installed and we don't even need to install it ourselves?

EDIT: My bad. cert-manager has been installed in advance by my already by mistake.

mrsimonemms commented 2 years ago

@corneliusludmann yes, that's my guess that it was already in your cluster. Even though I don't think this will be common, we ought to defensively code against it