mirror of
https://github.com/lrnselfreliance/wrolpi.git
synced 2026-11-20 15:06:19 -05:00
Installing python packages globally because it will make it easier to troubleshoot and start the services.
This commit is contained in:
parent
3ee34fef42
commit
d255a0839c
3 changed files with 15 additions and 6 deletions
15
50x.html
15
50x.html
|
|
@ -1,4 +1,4 @@
|
|||
<html>
|
||||
<html lang="en">
|
||||
<body>
|
||||
|
||||
<h1>Error!</h1>
|
||||
|
|
@ -8,9 +8,20 @@
|
|||
<p><b>sudo systemctl status wrolpi-app</b></p>
|
||||
<p><b>sudo systemctl status wrolpi-api</b></p>
|
||||
|
||||
<p>If either of those services are not running, start it:</p>
|
||||
<br/>
|
||||
<p>If either of those services are not running, start all WROLPi services:</p>
|
||||
|
||||
<p><b>sudo systemctl start wrolpi.target</b></p>
|
||||
|
||||
<br/>
|
||||
<p>Or, start them individually:</p>
|
||||
<p><b>sudo systemctl start wrolpi-app</b></p>
|
||||
<p><b>sudo systemctl start wrolpi-api</b></p>
|
||||
|
||||
<hr/>
|
||||
|
||||
<h2>Can't start the services?</h2>
|
||||
<p>You can view the media directory by <a href="/media">clicking here</a></p>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
|
|
|
|||
|
|
@ -64,8 +64,6 @@ pip3 --version || (
|
|||
curl https://bootstrap.pypa.io/get-pip.py -o /tmp/get-pip.py &&
|
||||
python3 /tmp/get-pip.py
|
||||
)
|
||||
python3 -m venv /opt/wrolpi/venv
|
||||
. /opt/wrolpi/venv/bin/activate
|
||||
|
||||
# Install python requirements files
|
||||
pip3 install -r /opt/wrolpi/requirements.txt
|
||||
|
|
@ -85,7 +83,7 @@ sudo -u postgres psql -c '\l' | grep wrolpi || (
|
|||
sudo -u postgres createdb -O wrolpi wrolpi
|
||||
)
|
||||
# Initialize the WROLPi database.
|
||||
(cd /opt/wrolpi && /opt/wrolpi/venv/bin/python3 /opt/wrolpi/main.py db upgrade)
|
||||
(cd /opt/wrolpi && /usr/bin/python3 /opt/wrolpi/main.py db upgrade)
|
||||
|
||||
# Install the WROLPi nginx config over the default nginx config.
|
||||
cp /opt/wrolpi/nginx.conf /etc/nginx/nginx.conf
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ PartOf=wrolpi.target
|
|||
|
||||
[Service]
|
||||
Environment=PYTHONUNBUFFERED=1
|
||||
ExecStart=/opt/wrolpi/venv/bin/python /opt/wrolpi/main.py api
|
||||
ExecStart=/usr/bin/python3 /opt/wrolpi/main.py api
|
||||
Group=wrolpi
|
||||
User=wrolpi
|
||||
WorkingDirectory=/opt/wrolpi/
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue