Closed EamonKeane closed 1 year ago
Thanks for creating the issue @EamonKeane. Our team will give it a closer look soon!
Just to be sure, you are taking about installing the kubefirst console UI to create a new cluster (as in the steps listed at https://docs.kubefirst.io/civo/quick-start/install/ui in the "Helm (ARM / M1 Mac / M2 Mac)" tab, right? If it's the case, it's not using the GitOps catalog: the catalog only helps you to install new applications to your created management cluster.
In the case, when exactly do you get the log-in issue? I tried to replicate, and when following the steps listed in the documentation I shared, even when killing all pods, the console still work as intended. Or is it after you created a cluster with the console UI?
I used the regular cli install. The easiest way to reproduce is to install using the cli, and then port-forward the mongodb container to a database viewer (e.g. Datagrip). Try use the login credentials that are listed on the kubefirst api pod. They won't work, because the user isn't created.
@EamonKeane: oh OK, now I understand, let me check if I can reproduce.
I can reproduce the same on my arm64 (MacBook M1 Pro). Let me check with the engineering team.
For other stumbling on this thread, that would explain that the provisioned services and the catalog in the console app are empty after a pod or cluster restart.
I think there might be a bug when using kubefirst for mongodb with arm on 2.2.17. As bitnami don't have an arm image, the gitops catalogue uses the official mongo one. However the official mongo image looks for different env vars for the username and password (
MONGO_INITDB_ROOT_USERNAME
for the official image butMONGO_ROOT_USER
for bitnami as they appear to have some extra logic for primary vs secondary). Specifically, I think the env vars for k3d-arm need to be like so:helm install mongo-test --version 13.18.1 oci://registry-1.docker.io/bitnamicharts/mongodb --namespace kubefirst --set image.repository=arm64v8/mongo --set image.tag=7.0.1 --set persistence.mountPath=/data/db --set "extraEnvVars[0].name=MONGO_INITDB_ROOT_USERNAME" --set "extraEnvVars[0].value=root" --set "extraEnvVars[1].name=MONGO_INITDB_ROOT_PASSWORD" --set "extraEnvVars[1].value=root"
The env vars for the kubefirst 2.2.17 deployed console looks like the below which is ignored. No user is created and so the authentication fails after a pod restart.
If they were like this I think it works.