#Can't find port

12 messages · Page 1 of 1 (latest)

daring saddle
#

I use django and can't use the public port, why
I set port in 8000

barren heronBOT
#

Project ID: 7907c068-57d6-4b57-a092-d05420c72c2a

daring saddle
#

7907c068-57d6-4b57-a092-d05420c72c2a

gaunt stump
#

you are using a development server, this is not fit to run on railway, so let's get you using something better.

please add gunicorn to your requirements.txt file.

what is the name of the folder that contains your wsgi.py file?

daring saddle
#

yes, I have in my core setting

gaunt stump
#

do you mean core folder?

daring saddle
#

JH_RestAPI wsgi is in this

gaunt stump
#

please add gunicorn to your requirements.txt file.

daring saddle
#

OK, I add to pyproject.toml

gaunt stump
#

ah yeah thats good to

#

add this railway.json file to your project

{
  "$schema": "https://schema.up.railway.app/railway.schema.json",
  "deploy": {
    "startCommand": "python manage.py migrate && python manage.py collectstatic --noinput && gunicorn JH_RestAPI.wsgi"
  }
}
daring saddle
#

THX, it can deploy successful