forked from RunestoneInteractive/rs
-
Notifications
You must be signed in to change notification settings - Fork 0
/
sample.env
58 lines (46 loc) · 2.63 KB
/
sample.env
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
# Copy this file to .env docker-compose will read and use the values from here.
# The build.py script is also aware of this file and if you run `poetry self add
# poetry-dotenv-plugin` when you run `poetry shell` it will also pick up these
# variables and add them to your environment.
# Where is the runestone app located (inside the container)
RUNESTONE_PATH = /usr/local/lib/python3.10/site-packages/rsptx/web2py_server/applications/runestone
# Database URLs: You may want to have a couple of different environment
# variables set up that essentially point to the same database. Therefore we use
# one set of variables for use within docker, prefixed with DC_ and another pair
# for use outside of docker. The DC variants should only be set in this file for
# use with docker-compose. (If you don't set the DC_ variables, docker compose
# will fall back to the other pair.)
DBURL = postgresql://runestone:runestone@localhost/runestone
DC_DBURL = postgresql://runestone:[email protected]/runestone
DEV_DBURL = postgresql://runestone:runestone@localhost:2345/runestone_dev
DC_DEV_DBURL = postgresql://runestone:runestone@db/runestone_dev
# for single configurations it is fine to use the redis configured in docker-compose
# however, for load balanced configurations you want to run a redis server that is
# shared by all the workers.
REDIS_HOST = redis
# Server configuration (production, development, or test)
# You should not set these to test as that is for our testing framework, not for
# people who are just testing out Runestone.
SERVER_CONFIG=development
WEB2PY_CONFIG=development
# The path to runestone books (on the host) In the container is set to /books
BOOK_PATH=~/Runestone/books
## !! change these if running a real server !!
# This replaces the private/auth.key file for web2py
WEB2PY_PRIVATE_KEY = sha512:24c4e0f1-df85-44cf-87b9-67fc714f5653
# This is the secret key for the javascript web token
JWT_SECRET = supersecret
# Set up host names
# localhost is ok for development, but you should set this to the real hostname
# if running a remote development server or definitely for production
RUNESTONE_HOST = localhost
# for production where you run a front end load balancer
# LOAD_BALANCER_HOST = localhost
# If you want nginx to install a certificate
# CERTBOT_EMAIL = [email protected]
# For setting production (or development) runtime parameters
# any UVICORN options can be set as an environment variable using the UVICORN_ prefix
# for gunicorn we can add additional runtime parameters with the GUNICORN_CMD_ARGS variable
# for uvicorn in production recommend 2 * cores + 1
UVICORN_WORKERS=5
GUNICORN_CMD_ARGS="--workers=3 --log-level 'debug'"