CORS Issue
sam422
HOBBYOP

6 days ago

Application frontend is seeing CORS issue, it is working in the morning.
I created a custom domain and configured it properly. It is protected by cloudflare. It is working fine. I reverted custom domain configuration

Solved$10 Bounty

Pinned Solution

sam422
HOBBYOP

6 days ago

here is what fixed, when I set custom domain to custom port 443, I see CORS issue, I changed it to 8080 which backend is exposed, it started working

6 Replies

Status changed to Awaiting Railway Response Railway 6 days ago


Did you add the custom domain to your CORS rules?


sam422
HOBBYOP

6 days ago

Yes I did in railway app variables, anyother place to define the cors rules?


You should be configuring CORS in your backend service, not just through environment variables. (Unless your backend CORS value relies on variables?)


sam422
HOBBYOP

6 days ago

thanks I'll implement CORS in backend, I can use 443 as custom port for custom domain right?


The port depends on whatever port your application is listening on.


sam422
HOBBYOP

6 days ago

here is what fixed, when I set custom domain to custom port 443, I see CORS issue, I changed it to 8080 which backend is exposed, it started working


Status changed to Solved ray-chen 5 days ago


Loading...