ALLOWED_HOSTNAMES environment variable breaks app startup
-
In our Cal.com app logs, I noticed these two lines:
WARN orgDomains.ts Match of WEBAPP_URL with ALLOWED_HOSTNAME failed ... ... ALLOWED_HOSTNAMES: []
I modified the
env
file to specifyALLOWED_HOSTNAMES
using the format demonstrated upstream (see .env.example#L64), but this made the app fail on startup.I suspect that the issue here may be that the requested list syntax (
'"a","b","c"'
) is somehow getting modified when Cloudron'senv
file is included in the Cal.com.env
file. -
-
Noting that this may be part of the problem underlying issue https://forum.cloudron.io/topic/9969/err_invalid_url-upstash-log-entries-sidequest-disable-telemetry-signup
-
@sparkwise https://github.com/calcom/cal.com/issues/12201 is the upstream issue (despite closed, the issue exists)
-
Problem solved! With these two in my
env
file, I'm no longer seeing the error messages:
NEXT_PUBLIC_WEBAPP_URL=https://cal.example.com
ALLOWED_HOSTNAMES='"example.com","cal.example.com"'
(I suspect that the first hostname is sufficient on its own. Haven't yet tried removing the second one.) -
-