This respository uses Poetry to manage Python dependencies.
You need to have a Python interpreter higher than 3.8
These environment variables are used for config NOJ backend:
MONGO_HOST
: host to MongoDB, used by mongoengine.connect
REDIS_HOST
/ REDIS_PORT
: host and port to RedisJWT_EXP
: JWT expiration in daysJWT_ISS
: JWT issuer, e.g. noj.tw
JWT_SECRET
: JWT secret, ensure that you set a strong enough value in productionSMTP_SERVER
: SMTP serverSMTP_NOREPLY
: email account used to send emails, e.g. noreply@noj.tw
SMTP_NOREPLY_PASSWORD
: password of SMTP_NOREPLY
(optional)SERVER_NAME
: hostname used in external link (without schema), e.g. api.noj.tw
APPLICATION_ROOT
: the path that flask app is mounted, also used to generate external link, e.g. /api
. default to /