为什么没有对古尼康的命令

2024-10-04 05:26:04 发布

您现在位置:Python中文网/ 问答频道 /正文

我查过这个:

pip3 install gunicorn

然后我试图管理古尼科恩,但我被告知没有这样的命令。如果我这样做:

^{pr2}$

我看到了这个:

.
..
app
arbiter.py
argparse_compat.py
_compat.py
config.py
debug.py
errors.py
glogging.py
http
__init__.py
instrument
pidfile.py
__pycache__
reloader.py
selectors.py
six.py
sock.py
systemd.py
util.py
workers

我在想我可以创建一个符号链接并存储在这里:

/usr/local/bin/

但我要链接什么呢?看起来好像没有真正的古尼科恩指挥部?在

如果我看这里:

https://github.com/benoitc/gunicorn

没有名为“gunicorn”的文件。同样,如果我看这里:

https://github.com/benoitc/gunicorn/gunicorn

据我所知,没有一个文件叫做“gunicorn”。那么我们应该如何从命令行调用它呢?在


Tags: install文件pyhttps命令githubcomapp
3条回答

你可以用两种方法安装gunicorn

如果你想安装操作系统级的软件,试试ubuntu sudo apt install gunicorn 或者pip样式pip install gunicorn-这是可以暗示的

要检查是否已安装,请尝试以下命令

$ pip show gunicorn
Name: gunicorn
Version: 19.9.0
Summary: WSGI HTTP Server for UNIX
Home-page: http://gunicorn.org
Author: Benoit Chesneau
Author-email: benoitc@e-engura.com
License: MIT
Location: /home/<user>/anaconda3/lib/python3.6/site-packages
Requires: 
Required-by:

请告诉我我对你问题的理解是否正确。在

如果您使用的是virtualenv,那么gunicorn将在中创建

/path_to_your_env/bin/gunicorn

因此,无论何时尝试使用gunicorn,都需要首先加载virtualenv,然后执行gunicorn命令。在

如果你有apt(或apt get):

$ sudo apt install gunicorn3

$ sudo ln -s /usr/bin/gunicorn3 /usr/bin/gunicorn

您可能需要先删除旧的gunicorn包:

^{pr2}$

检查gunicorn3的安装位置(以防万一):

$ whereis gunicorn3

相关问题 更多 >