Hey folks, what's the general flow people follow w...
# ory-network
h
Hey folks, what's the general flow people follow when building their frontends on localhost, and pointing it to a production Ory instance? We have Ory on a custom domain, but our frontend engineer is having trouble pointing to Ory as it redirects to the production UI, rather than to
localhost
. Is there a neat way to simplify this flow, without requiring our FE engineer having to setup have of Ory services? Tries
tunnel
/`proxy` but to no avail
๐Ÿคจ 1
FWIW --
localhost:3000
is considered an allowed redirect URL, but using the
return_to
parameter does not seem to work:
Copy code
curl -X GET '<project-slug>/self-service/login/browser?return_to=<http://localhost:3000>'
<a href="/ui/login?flow=<flow-id>">See Other</a>.
Using the flow uri simply redirects us to the production page again despite the
return_to
parameter in the flow creation request. Setting the
return_to
to a non-allowed uri however does result in an error.
b
following
h
Honestly it's been really tough to get working. The
ory proxy
cli hardcodes the CORS config, which results in duplicate CORS headers being sent, so that causes the browser to fail.
b
Yeah, hasn't been great ๐Ÿ˜•
h
The only way I got round to fixing this was literally forking and patching the
ory
cli to remove duplicate heeaders
Opened an issue with the details - https://github.com/ory/cli/issues/344