2 years ago
Hi guys ! Sorry for the noob question...
I have set up a postgresql on railway and I would like to connect it to my vercel front-end.
I have a question for the environment variable :
datasource db {
provider = "postgresql"
url = env("DATABASE_URL")
directUrl = env("DIRECT_URL")
}
For the variables, should I use the DATABASE_PUBLIC_URL proxied env from Railway or I need to create a custom domain in the Settings -> Networking -> Public Networking
Thank you for your help 🙂
5 Replies
2 years ago
Since your frontend is on vercel and not on railway, u will need to use the public URL
2 years ago
That will make your project get some egress fees though, since they aren't on the same private network.
2 years ago
may I ask why not run your frontend on railway too?