WGDashboard icon indicating copy to clipboard operation
WGDashboard copied to clipboard

Followed step by step guide but can’t run showing gunicorn command not found

Open iamjamilkhan opened this issue 2 years ago • 4 comments

I have followed step by step guide but still can’t run dashboard. While starting its showing Starting WGDashboard with Gunicorn in the background. | ./wgd.sh: line 104: gunicorn: command not found | Log files is under log Uploading A630D2F8-4E11-45BD-8E0B-3C3197F57B9F.png…

iamjamilkhan avatar Jun 24 '22 20:06 iamjamilkhan

sudo apt install gunicorn

sudo apt-get update sudo apt-get -y install python3-pip

xNetos avatar Jun 27 '22 13:06 xNetos

You should install pip for your distribution, then run pip install -r requirements.txt (sometimes the command is pip3, for Python3 installations) from the src directory. This will install all dependencies, including gunicorn.

theonlynexus avatar Jul 20 '22 07:07 theonlynexus

The same problem. Apparently ./wgd.sh install silently ignored all problems, and pip dependencies were not installed.

pip install -r requirements.txt fails with another error:

error: externally-managed-environment

× This environment is externally managed
╰─> To install Python packages system-wide, try apt install
    python3-xyz, where xyz is the package you are trying to
    install.

    If you wish to install a non-Debian-packaged Python package,
    create a virtual environment using python3 -m venv path/to/venv.
    Then use path/to/venv/bin/python and path/to/venv/bin/pip. Make
    sure you have python3-full installed.

    If you wish to install a non-Debian packaged Python application,
    it may be easiest to use pipx install xyz, which will manage a
    virtual environment for you. Make sure you have pipx installed.

    See /usr/share/doc/python3.11/README.venv for more information.

note: If you believe this is a mistake, please contact your Python installation or OS distribution provider. You can override this, at the risk of breaking your Python installation or OS, by passing --break-system-packages.
hint: See PEP 668 for the detailed specification.

Ok, it seems it is possible to activate a venv (https://stackoverflow.com/a/75696359/6210104). I am not sure though, how can I start it then and how can I make it to autorun on startup 🤔 Or should we run pip install -r requirements.txt --break-system-packages?

egorshulga avatar Oct 21 '23 12:10 egorshulga

I have the same problem. I have Python 3.11 and pip3 installed. If I want to run ./wgd.sh start

------------------------------------------------------------
| Starting WGDashboard with Gunicorn in the background.    |
./wgd.sh: line 104: gunicorn: command not found
| Log files is under log/                                  |
------------------------------------------------------------

Installing Gunricon

sudo pip install gunicorn

error: externally-managed-environment

× This environment is externally managed
╰─> To install Python packages system-wide, try apt install
    python3-xyz, where xyz is the package you are trying to
    install.
    
    If you wish to install a non-Debian-packaged Python package,
    create a virtual environment using python3 -m venv path/to/venv.
    Then use path/to/venv/bin/python and path/to/venv/bin/pip. Make
    sure you have python3-full installed.
    
    If you wish to install a non-Debian packaged Python application,
    it may be easiest to use pipx install xyz, which will manage a
    virtual environment for you. Make sure you have pipx installed.
    
    See /usr/share/doc/python3.11/README.venv for more information.

note: If you believe this is a mistake, please contact your Python installation or OS distribution provider. You can override this, at the risk of breaking your Python installation or OS, by passing --break-system-packages.
hint: See PEP 668 for the detailed specification.

I'm using LXC Debian 12

xgusto avatar Feb 12 '24 20:02 xgusto