https://www.ory.sh/ logo
m

many-garden-6507

04/21/2022, 9:26 AM
HI, i am following this example https://www.ory.sh/login-spa-react-nextjs-authentication-example-api-open-source/ I want to use docker version for local environment, the docker-compose is up and i have use this command
export ORY_KRATOS_URL=<http://localhost:4438/>
and now when i run the npm run dev and click on sign up i get the following error
Here is the docker-compose output
@User @User
p

proud-plumber-24205

04/21/2022, 11:05 AM
Hi @User is there a prefix added to the path? such as
/.ory
m

magnificent-energy-493

04/21/2022, 11:07 AM
shouldn’t it be
Copy code
export ORY_KRATOS_URL=<http://localhost:4455/>
? Or did you change the docker-compose? in that case please post it here.
m

many-garden-6507

04/21/2022, 11:25 AM
It was port issue🤦‍♂️ working now.
Ok so now i am working on protecting the routes so if the user is not authenticated i can re route them to login page and for that i need session information, so that i can fetch it inside useeffect hook and if the session is there i can keep that route otherwise resend it to login page.
m

magnificent-energy-493

04/21/2022, 11:32 AM
sounds good yes
3 Views