Switch railway.json startCommand to module serve, use PORT variable

This commit is contained in:
2024-11-01 16:02:40 -05:00
parent 267abfe792
commit 796c28d72d
2 changed files with 3 additions and 1 deletions

View File

@@ -1,3 +1,4 @@
import os
import sys
import structlog
@@ -17,6 +18,7 @@ def main(*args):
"linkpulse.app:app",
reload=True,
host="0.0.0.0",
port=int(os.getenv("PORT", "8000")),
log_config={
"version": 1,
"disable_existing_loggers": False,

View File

@@ -4,6 +4,6 @@
"builder": "NIXPACKS"
},
"deploy": {
"startCommand": "hypercorn linkpulse.app:app --bind \"[::]:$PORT\""
"startCommand": "python3 -m linkpulse serve"
}
}