better readme
This commit is contained in:
@@ -126,11 +126,11 @@ credentials outside the web root:
|
|||||||
|
|
||||||
```sh
|
```sh
|
||||||
sudo useradd --system --create-home --shell /usr/sbin/nologin fasthue
|
sudo useradd --system --create-home --shell /usr/sbin/nologin fasthue
|
||||||
sudo mkdir -p /opt/fasthue /etc/fasthue
|
sudo mkdir -p /srv/fasthue /etc/fasthue
|
||||||
sudo chown fasthue:fasthue /opt/fasthue /etc/fasthue
|
sudo chown fasthue:fasthue /srv/fasthue /etc/fasthue
|
||||||
# Copy this project into /opt/fasthue, then:
|
# Copy this project into /srv/fasthue, then:
|
||||||
sudo -u fasthue python3 -m venv /opt/fasthue/.venv
|
sudo -u fasthue python3 -m venv /srv/fasthue/.venv
|
||||||
sudo -u fasthue /opt/fasthue/.venv/bin/pip install -r /opt/fasthue/requirements.txt
|
sudo -u fasthue /srv/fasthue/.venv/bin/pip install -r /srv/fasthue/requirements.txt
|
||||||
sudo install -o fasthue -g fasthue -m 600 secrets.yaml /etc/fasthue/secrets.yaml
|
sudo install -o fasthue -g fasthue -m 600 secrets.yaml /etc/fasthue/secrets.yaml
|
||||||
```
|
```
|
||||||
|
|
||||||
@@ -147,11 +147,11 @@ Type=exec
|
|||||||
User=fasthue
|
User=fasthue
|
||||||
# Use your Nginx worker group (commonly www-data; use nginx on some distros).
|
# Use your Nginx worker group (commonly www-data; use nginx on some distros).
|
||||||
Group=www-data
|
Group=www-data
|
||||||
WorkingDirectory=/opt/fasthue
|
WorkingDirectory=/srv/fasthue
|
||||||
Environment=FASTHUE_SECRETS_FILE=/etc/fasthue/secrets.yaml
|
Environment=FASTHUE_SECRETS_FILE=/etc/fasthue/secrets.yaml
|
||||||
RuntimeDirectory=fasthue
|
RuntimeDirectory=fasthue
|
||||||
RuntimeDirectoryMode=0750
|
RuntimeDirectoryMode=0750
|
||||||
ExecStart=/opt/fasthue/.venv/bin/gunicorn --workers 1 --umask 007 --bind unix:/run/fasthue/fasthue.sock --factory app:create_gunicorn_app
|
ExecStart=/srv/fasthue/.venv/bin/gunicorn --workers 1 --umask 007 --bind unix:/run/fasthue/fasthue.sock --factory app:create_gunicorn_app
|
||||||
Restart=on-failure
|
Restart=on-failure
|
||||||
RestartSec=3
|
RestartSec=3
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user