Require python3.9

This commit is contained in:
Riley Housden 2021-11-30 03:11:43 -05:00
parent 1b8489ad88
commit ffef9b6f07
Signed by: InValidFire
GPG key ID: 0D6208F6DF56B4D8
4 changed files with 8 additions and 3 deletions

5
README.md Normal file
View file

@ -0,0 +1,5 @@
# Radical API
Requires Python 3.9
I use this API for a variety of things, really it's just a collection of random stuff I add.

View file

@ -1,6 +1,6 @@
addgroup radical-api addgroup radical-api
adduser --system --home /otp/radical-api --ingroup radical-api radical-api adduser --system --home /otp/radical-api --ingroup radical-api radical-api
sudo -u radical-api git clone https://gitdab.com/InValidFire/radical-api.git /otp/radical-api sudo -u radical-api git clone https://gitdab.com/InValidFire/radical-api.git /otp/radical-api
sudo -u radical-api python3 -m pip install -r /otp/radical-api/requirements.txt sudo -u radical-api python3.9 -m pip install -r /otp/radical-api/requirements.txt
cp radical-api.service /etc/systemd/system cp radical-api.service /etc/systemd/system
systemd enable radical-api systemd enable radical-api

View file

@ -2,7 +2,7 @@ import sys
from core.wrapper import Wrapper from core.wrapper import Wrapper
api = Wrapper(['python3', '-m', 'gunicorn', "-k", "uvicorn.workers.UvicornWorker", api = Wrapper(['python3.9', '-m', 'gunicorn', "-k", "uvicorn.workers.UvicornWorker",
"--log-config", "log.conf", "--log-config", "log.conf",
'--bind', '0.0.0.0:8000', '--bind', '0.0.0.0:8000',
'api:api'], sys.stdout) 'api:api'], sys.stdout)

View file

@ -9,7 +9,7 @@ User=radical-api
Group=radical-api Group=radical-api
Restart=on-failure Restart=on-failure
RestartSec=20 3 RestartSec=20 3
ExecStart=/usr/bin/env python3 /otp/radical-api/main.py ExecStart=/usr/bin/env python3.9 /otp/radical-api/main.py
[Install] [Install]
WantedBy=multi.user.target WantedBy=multi.user.target