has taken too long to respond.
Hi. I just uploaded my Monorepo and it's working good on logs. But when I try to access to:
https://tidyfreshv2-production.up.railway.app:7452/
it says "Has taken to long to respond" I'm new on this, so if you can help me would be great. My stack is nestjs and nextjs for my monorepo builded with Turbopack
51 Replies
Project ID:
93040d23-f028-4588-bd14-9ae6bb951e4d
ProjectID: 93040d23-f028-4588-bd14-9ae6bb951e4d
you can only access your app over port 443
https://tidyfreshv2-production.up.railway.app/
And what about if I'm trying to submit a mono repo. Do I need to have 2 differents projects, right?
one project, two railway services
Cool, thanks for your help buddy. I really appreciate it 🙂
no problem, what two apps do you have if you dont mind me asking
I have frontend (nextjs) and backend (nestjs). On my local I was using docker and monorepo with Turbo. Also, I have postgres Db
the package.json in the root would need to have two sets of scripts, one set of build and start scripts that build and start only the frontend, and another set that only build and start the backend, typically that would look something like this
then in each railway service youd set the appropriate build and start commands in the service settings, for instance the frontend service would have the build command set to
npm run build:frontend
and the start command set to npm run start:frontend
turbo provides a way to build and start specific apps, i dont know that syntax for that off the top of my head, but that should give you a good understandingHi, boss (again) @Brody . I just initialize another service just with the backend. Again, everything is good on logs but the same issue is taken so long to respond.
you still cant use anything but port 443 when connecting to your service externally
I manually put 443 on environment variables. https://apitidy-production.up.railway.app/
Logs:
[Nest] 42 - 11/14/2023, 3:47:31 AM LOG [NestApplication] Nest application successfully started +3ms
Application is running on: http://[::1]:443
not quite what you wanna do
https://docs.railway.app/troubleshoot/fixing-common-errors#node--nest
I literally followed this guide:
// Use
PORT
provided in environment or default to 3000
const port = process.env.PORT || 3000;
// Listen on port
and 0.0.0.0
async function bootstrap() {
// ...
await app.listen(port, "0.0.0.0");
}
my main.ts is following this documentation :/what do your new deploy logs look like?
looks like your app is running on 127.0.0.1 instead of 0.0.0.0
this is my main.ts, just in case I need to change something
think that looks good, send me the url please
Railway url?
https://apitidy-production.up.railway.app/
it works?
Nop :c
wtf, for me does not work. Maybe I need to clear cache
Let me try, thanks boss for your help
its always cache lol
haha
does it work now?
Not for me, same issue. :/
what url are you trying
are you sure you arent trying to specify a port?
100% sure
try a different browser?
I tried brave, edge and chrome. I will try to restart my router just to make sure
try a vpn too?
Tried vpn still same issue
lol
vpn to my location, us-east
I just changed the region and it works. Why is that issue? I also need to be work on my region :/
the region on the vpn?
I just changed to USA
whats your region?
Dominican Republic
Is this for any particular issue?
no one has reported any outages
That's weird. I tested using other locations like UK, Spain and everything works. But, when I turn off the vpn does not work anymore. I send the link to some friends from my country as well just to see if on their end works and it doesn't
lol
could this be an isp firewall?
That could be the issue, somtehing that I can do on my end to solve it?
if its an isp firewall you dont have many options, use a vpn is about it
Definitively I just tried with another ISP and it works. But, my ISP is the most popular ISP on my country 😦
thats not ideal
any recommendation? I don't want to use other service than railway, I really like this service lol
i dont really know what to tell you, theres not much railway can do for you if your isp is blocking you