小编Muh*_*bad的帖子

uWSGI和Python> 3.4

我有一个django项目,当前正在使用以下配置运行:

  • Debian 8
  • Python 3.4
  • 皇帝模式下的uWSGI

我从源代码安装了Python 3.6.1,并使用python 3.6创建了一个新的虚拟环境(我使用virtualenvwrapper),但是让该项目以uwsgi启动似乎有些麻烦。

配置文件如下:

[uwsgi]
plugins = python3
project = %n
module = myapp.wsgi:application
home = path_to_new_env
socket = /var/run/uwsgi-%n.sock
chdir = path_to_new_env/myapp/myapp
processes = 4
max-requests = 5000
chmod-socket = 666
chown-socket = user:user
master = True
vacuum = True
logto = /var/log/%n_LOG.log
buffer-size = 32768
Run Code Online (Sandbox Code Playgroud)

我的印象是该python3插件将包括对python 3.6的支持,但日志表明仍在使用Python 3.4.x解释器。

在已安装的uwsgi插件列表中,我看到了对python 2、3和3.4的支持,但仅此而已。我不确定启动时设置正确的解释器需要做什么。

任何意见,将不胜感激。

更新:我已经尝试为python 3.6构建一个uwsgi插件:

root@app:~# PYTHON=python3.6 uwsgi --build-plugin "/root/uwsgi-2.0.15/plugins/python python36"
*** uWSGI building and linking plugin from /root/uwsgi-2.0.15/plugins/python ***
[gcc -pthread] …
Run Code Online (Sandbox Code Playgroud)

django uwsgi python-3.6

5
推荐指数
2
解决办法
3922
查看次数

标签 统计

django ×1

python-3.6 ×1

uwsgi ×1