You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I inspected the verbose debug output with the -v, --verbose flag.
Are you an Up Pro subscriber?
Description
After deploying my Prisma server using up I get this error when I navigate to the deployed URL: {"message": "Internal server error"} when checking logs I see the following
Mar 19th 01:39:26pm INFO staging 5e3a8b1 initializing
Mar 19th 01:39:26pm INFO staging 5e3a8b1 starting app: PORT=35343 command=ts-node index.ts
Mar 19th 01:39:26pm INFO staging 5e3a8b1 started app
Mar 19th 01:39:26pm INFO staging 5e3a8b1 waiting for app to listen on PORT
Mar 19th 01:39:41pm FATA staging 5e3a8b1 error creating handler: waiting for http://127.0.0.1:35343 to be in listening state: timed out after 15s: name=tracket-server type=server
Mar 19th 01:39:41pm INFO 2020-03-19T20:39:41.086Z d104c092-c99a-434a-a700-9adc30841dfe ERROR [shim] exit: code=1 signal=null
2.121s Mar 19th 01:39:41pm INFO REPORT RequestId: d104c092-c99a-434a-a700-9adc30841dfe Duration: 15134.81 ms Billed Duration: 15200 ms Memory Size: 512 MB Max Memory Used: 182 MB
DEBU request Mar 19th 01:39:41pm INFO RequestId: d104c092-c99a-434a-a700-9adc30841dfe Error: Runtime exited with error: exit status 1
Runtime.ExitError
However when running the deployment server using up start -v I get a working server and the following output in my console:
⠋ 7ms DEBU up version 1.5.1 (os: darwin, arch: amd64) Mar 19th 01:41:49pm DEBU inferred runtime: type=node
Mar 19th 01:41:49pm DEBU 1 regions from config
Mar 19th 01:41:49pm DEBU track "Start" map[address:localhost:3000 arch:amd64 ci:false has_command:false os:darwin version:1.5.1]
Mar 19th 01:41:49pm INFO starting app: PORT=63980 command=ts-node index.ts
Mar 19th 01:41:49pm INFO started app
Mar 19th 01:41:49pm INFO waiting for app to listen on PORT
⠸ 8.403s DEBU up version 1.5.1 (os: darwin, arch: amd64) Mar 19th 01:41:58pm INFO Server is running on http://localhost:63980
⠋ 9.101s DEBU up version 1.5.1 (os: darwin, arch: amd64) Mar 19th 01:41:59pm INFO app listening: duration=9.098s
Mar 19th 01:41:59pm DEBU header rules from _headers file: 0
Mar 19th 01:41:59pm DEBU header rules from up.json: 0
Mar 19th 01:41:59pm INFO listening: address=http://localhost:3000
⠸ 26.401s DEBU up version 1.5.1 (os: darwin, arch: amd64) Mar 19th 01:42:16pm INFO request: ip=127.0.0.1:64053 method=GET path=/
Mar 19th 01:42:16pm INFO response: duration=23ms ip=127.0.0.1:64053 method=GET path=/ size=3.0 kB status=200
⠼ 28.501s DEBU up version 1.5.1 (os: darwin, arch: amd64) Mar 19th 01:42:18pm INFO request: ip=127.0.0.1:64060 method=POST path=/ size=1.5 kB
are you connecting to a database before calling listen(PORT)? Maybe there's a permission issue preventing it from getting there, the "waiting to be in listening state" means your app isn't listening on the port provided by the PORT env var.
It might be useful to throw a few console.log()s in your app to see if it gets stuck before reaching listen()
@tj Thanks for the help! After throwing some logs into the app, I'm seeing that it never enters index.ts on the staging server. However on the local development server, I see the logging.
Up uses app.js as the default for Node.js, but it'll use npm start's script if you have that. Just a guess but maybe package.json is in .upignore? That could prevent it from using the correct command.
Alternatively you could try:
{
"proxy": {
"command": "node index.js"
}
}
To make it explicit. It should error though if it can't find app.js, so I might be wrong about that
I don't have a .upignore in my project so that's not the issue. I just added my start command (ts-node index.ts to my config and its still resulting in the same thing.
Prerequisites
up upgrade
)-v, --verbose
flag.Description
After deploying my Prisma server using
up
I get this error when I navigate to the deployed URL:{"message": "Internal server error"}
when checking logs I see the followingHowever when running the deployment server using
up start -v
I get a working server and the following output in my console:Repo: https://github.com/tracket-dev/tracket-server
The text was updated successfully, but these errors were encountered: