Install » History » Version 3
Viacheslav Anzhiganov, 11/26/2025 02:41 PM
| 1 | 1 | Viacheslav Anzhiganov | # Install |
|---|---|---|---|
| 2 | |||
| 3 | ```shell |
||
| 4 | dnf install -y epel-release |
||
| 5 | dnf install -y nginx supervisor |
||
| 6 | ``` |
||
| 7 | |||
| 8 | |||
| 9 | ```shell |
||
| 10 | systemctl enable supervisord |
||
| 11 | systemctl start supervisord |
||
| 12 | ``` |
||
| 13 | 2 | Viacheslav Anzhiganov | |
| 14 | ## supervisor config |
||
| 15 | |||
| 16 | ```shell |
||
| 17 | vi /etc/supervisord.d/domainparking.ini |
||
| 18 | ``` |
||
| 19 | |||
| 20 | ```init |
||
| 21 | [program:domainparking] |
||
| 22 | command = /opt/parking/.venv/bin/uvicorn app.main:app --host 0.0.0.0 --port 8000 --reload |
||
| 23 | directory = /opt/parking |
||
| 24 | # user = www |
||
| 25 | autostart=true |
||
| 26 | ``` |
||
| 27 | 3 | Viacheslav Anzhiganov | |
| 28 | ## nginx config |
||
| 29 | |||
| 30 | |||
| 31 | ``` |
||
| 32 | server { |
||
| 33 | listen 80; |
||
| 34 | listen [::]:80; |
||
| 35 | server_name _; |
||
| 36 | #root /usr/share/nginx/html; |
||
| 37 | root /opt/parking/frontend; |
||
| 38 | |||
| 39 | # Load configuration files for the default server block. |
||
| 40 | include /etc/nginx/default.d/*.conf; |
||
| 41 | |||
| 42 | error_page 404 /404.html; |
||
| 43 | location = /404.html { |
||
| 44 | } |
||
| 45 | |||
| 46 | error_page 500 502 503 504 /50x.html; |
||
| 47 | location = /50x.html { |
||
| 48 | } |
||
| 49 | } |
||
| 50 | ``` |