fullheartF
Convex Community5mo ago
2 replies
fullheart

Local development with none-localhost domain without HTTPS as "CONVEX_SITE_ORIGIN"?

For the locally hosted Convex backend, I use the domain http://site.convex.local instead of http://127.0.0.1:3211 for CONVEX_SITE_ORIGIN during development.

Unfortunately, I get this error with
npx convex dev
:

The pushed auth config is invalid: Invalid provider domain URL ‘http://site.convex.local’: must use HTTPS

This error is thrown by this validation code:
https://github.com/get-convex/convex-backend/blob/main/crates/common/src/auth.rs#L208-L220

QUESTION 1 How can this be resolved so that not ONLY
localhost
is supported as a domain for local development without HTTPS?

As a workaround, I can set the env variable like this CONVEX_SITE_ORIGIN=http://127.0.0.1:3211.
QUESTION 2: But are there any side effects if I use http://site.convex.local in the frontend?
Was this page helpful?