Enabling internal routing in uWSGI

前端 未结 2 487
粉色の甜心
粉色の甜心 2021-01-18 06:57

I have a Django app working with uWSGI. My uWSGI config is:

[uwsgi]
http = 127.0.0.1:8000
env = DJANGO_SETTINGS_MODULE=my_django_app.settings
module = my_dja         


        
2条回答
  •  [愿得一人]
    2021-01-18 07:53

    [uwsgi]

    base = /var/www/html/poopbuddy-api

    chdir = %(base)

    app = app

    I don't exactly know what chdir does, but I think it fixed it... I'm guessing it at least sets the default location to the app's root folder. Something like this also happens to me when I'm using PyCharm, I have to set "working directory" from the "Edit Configurations" or "edit/debug configuration" window.

提交回复
热议问题