-
-
Notifications
You must be signed in to change notification settings - Fork 264
Installing on virtualenv (linux)
Iaroslav Shepilov edited this page Dec 19, 2018
·
3 revisions
- Install python virtualenv using (replace
apt
with your package manager)sudo apt install python3-venv
- Create virtualenv named envname for python3 using
python3 -m venv any/path/envname
- Enter to virtual env
source any/path/envname/bin/activate
- Check python version using
python -V
- Create a folder for script server and navigate to it
mkdir -p any/path/script-server && cd any/path/script-server
- Download latest release
wget https://github.com/bugy/script-server/releases/download/1.12.0/script-server.zip
- Extract zip contents
unzip script-server.zip
(If unzip command not found, install unzip withsudo apt-get install unzip
) - Install requirements
pip install -r requirements.txt
- Run the server
python launcher.py
Bonus: If using virtualenv's python, then systemd startup script python path would be:
- Find out virtualenv's python path (When virtualenv is activated)
which python
copy result - Edit
/lib/systemd/system/script-server.service
ExecStart=/usr/bin/python3
would be ->paste here
Example something like this:/home/user/script-server/envname/bin/python
The similar change should be done for init.d