a year ago
I have the following isolated monorepo structure :
/-packages
- / api
- / app
But i'm just trying to deploy the api on railway only,. I've set the root directory to /packages/api/
and start command to node dist/server.js
each time it tries redeploying i keep getting the error message in the title above. Any idea how this can be resolved?
0 Replies
a year ago
project id: f59df6b2-c7e3-42ce-959a-4e436f2c5350
a year ago
here are the logs, btw, it only crash during deployment and not during build:
Starting Container
container event container died
node:internal/modules/cjs/loader:1189
throw err;
^
Error: Cannot find module '/app/dist/server.js'
at Module._resolveFilename (node:internal/modules/cjs/loader:1186:15)
at Module._load (node:internal/modules/cjs/loader:1012:27)
at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:158:12)
at node:internal/main/run_main_module:30:49 {
code: 'MODULE_NOT_FOUND',
requireStack: []
}
Node.js v22.2.0
Hi im using pnpm monorepo and the root always be root of monorepo for install dependencies purposes. In root package i have scripts for build, install and preinstall isolated services
a year ago
please open your own thread
a year ago
as for the OP of the thread, I'm going to close it out in favour of your post on the help station, going forward, please do not cross post.