Open mrvnklm opened 2 months ago
Thanks for reporting this bug. Can you provide the version of the Helm Chart and the used values.yaml please.
TL;DR: If you want to disable an environment variable, you can set it to an empty string.
I ran into the same error, and spent some time debugging this.
cloudMode
to "0"
, it resolves to "0"
in the code. cloudMode
to false
, it resolves to "0"
in the code.cloudMode
to ""
, it resolves to ""
in the code.If we look at the function canCreateWebsite
, it checks for the following:
if (cloudMode) {
return !!grant?.find(a => a === PERMISSIONS.websiteCreate);
}
Meaning that if you set cloudMode
to "0"
, this will happen:
if ("0") { // true
return !!grant?.find(a => a === PERMISSIONS.websiteCreate);
}
But if you set cloudMode
to ""
, this will happen:
if ("") { // false
return !!grant?.find(a => a === PERMISSIONS.websiteCreate);
}
So to fix this issue, you can set the variables to ""
if you want to make them effectively falsey in the code.
To me it doesn't seem like these boolean environment variables should be quoted, and it gives the opposite behaviour:
{{- if .Values.umami.cloudMode }}
- name: CLOUD_MODE
value: {{ .Values.umami.cloudMode | quote }}
{{- end }}
I installed the chart without any customizations and I am getting an 403 error if I want to change the default users password and 401 error if I want to create a team. I also tried
CLOUD_MODE: 0
and useDISABLE_LOGIN: 0
.