Python 当uwsgi构建单片(内置插件)并通过dnf安装在Fedora上时,如何使用uwsgi?

Python 当uwsgi构建单片(内置插件)并通过dnf安装在Fedora上时,如何使用uwsgi?,python,fedora,uwsgi,Python,Fedora,Uwsgi,我一直在努力克服恐惧 当我将python3指定为插件时,它似乎总是希望加载Python2.7 当我运行uwsgi--plugins list`时,我得到了: $ uwsgi --plugins-list *** uWSGI loaded generic plugins *** gevent nagios rrdtool carbon corerouter fastrouter http ugreen syslog rsyslog logsocket router_uwsgi router_re

我一直在努力克服恐惧

当我将python3指定为插件时,它似乎总是希望加载Python2.7

当我运行uwsgi--plugins list`时,我得到了:

$ uwsgi --plugins-list

*** uWSGI loaded generic plugins ***
gevent
nagios
rrdtool
carbon
corerouter
fastrouter
http
ugreen
syslog
rsyslog
logsocket
router_uwsgi
router_redirect
router_basicauth
zergpool
redislog
mongodblog
router_rewrite
router_http
logfile
router_cache
rawrouter
router_static
sslrouter
cheaper_busyness
transformation_tofile
transformation_gzip
transformation_chunked
transformation_offload
router_memcached
router_redis
router_hash
router_expires
router_metrics
transformation_template
stats_pusher_socket

*** uWSGI loaded request plugins ***
0: python
17: spooler
18: symcall
100: ping
110: signal
111: cache
173: rpc
--- end of plugins list ---
# uwsgi --plugins-list

*** uWSGI loaded generic plugins ***
corerouter

*** uWSGI loaded request plugins ***
100: ping
101: echo
--- end of plugins list ---

*** Starting uWSGI 2.0.14 (64bit) on [Sun Jan  8 11:42:22 2017] ***
compiled with version: 4.8.5 20150623 (Red Hat 4.8.5-4) on 05 October 2016 20:03:58
os: Linux-3.10.0-327.36.3.el7.x86_64 #1 SMP Mon Oct 24 16:09:20 UTC 2016
在CentOS服务器上运行
uwsgi--plugins list
时,我返回:

$ uwsgi --plugins-list

*** uWSGI loaded generic plugins ***
gevent
nagios
rrdtool
carbon
corerouter
fastrouter
http
ugreen
syslog
rsyslog
logsocket
router_uwsgi
router_redirect
router_basicauth
zergpool
redislog
mongodblog
router_rewrite
router_http
logfile
router_cache
rawrouter
router_static
sslrouter
cheaper_busyness
transformation_tofile
transformation_gzip
transformation_chunked
transformation_offload
router_memcached
router_redis
router_hash
router_expires
router_metrics
transformation_template
stats_pusher_socket

*** uWSGI loaded request plugins ***
0: python
17: spooler
18: symcall
100: ping
110: signal
111: cache
173: rpc
--- end of plugins list ---
# uwsgi --plugins-list

*** uWSGI loaded generic plugins ***
corerouter

*** uWSGI loaded request plugins ***
100: ping
101: echo
--- end of plugins list ---

*** Starting uWSGI 2.0.14 (64bit) on [Sun Jan  8 11:42:22 2017] ***
compiled with version: 4.8.5 20150623 (Red Hat 4.8.5-4) on 05 October 2016 20:03:58
os: Linux-3.10.0-327.36.3.el7.x86_64 #1 SMP Mon Oct 24 16:09:20 UTC 2016

我使用
dnf
在Fedora上安装了uwsgi。在CentOS上,它来自
yum
。如果这个问题的答案是通过pip安装,我会非常惊讶,因为这意味着Fedroa存储的版本使用有限,因为它是单片编译的

Fedora和EPEL(用于CentOS)中的uwsgi包是以一种大多数插件(python、ruby、psgi、php等)必须显式加载的方式构建的。当您从PyPI安装uwsgi时,它被构建为默认的python插件。因此,为了让它在通过RPM安装时工作,请按如下方式运行:

uwsgi --plugin python <then the rest of your normal arguments>
uwsgi——插件python

uwsgi——插件python3

最新(3.7版)的Alpine linux软件包似乎也是如此。