最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

python - Adjusting cPanel route for pip through SSH - Stack Overflow

programmeradmin2浏览0评论

I am still trying to figure it out how to run a Python app in cPanel.

A little of context: I have no access to WHM, so I can't enable terminal, nor other components, this is an important point since most of the tutorials use some modules I can't find in my cPanel's setup.

I was succesful into login via SSH, and during the attempt, I was able to run the web app, but now I am in this step of registering the webapp using Application Manager from cPanel. At this point I was using python3 and pip3 since the host has an already installed version of python and uses python and pip as variable, but these two won't work, so python3 and pip3 do the trick.

I also have to mention, I'm a limited user so, many features such as sudo are disabled, so removing, and or modifying user files is not an option.

Well, when I try to run the app from Application Manager, it requests me to verify by using:

cd /home2/user_name/web_app && /usr/bin/pip install --user -r requirements.txt

But this is actually trying to run pip instead of pip3. When I run that command I have the following error:

Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build-mdOeDX/gunicorn/

When I use pip3 instead:

Requirement already satisfied: ....

What alternatives I have?

What should I check?

Is there a way where I can indicate cPanel to use pip3 instead of pip?

Any suggestion is appreciated. Thanks in advance.

发布评论

评论列表(0)

  1. 暂无评论