aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Matteo Bertucci <[email protected]>2021-02-25 14:48:37 +0100
committerGravatar Matteo Bertucci <[email protected]>2021-02-25 14:48:37 +0100
commit3b20acf3d422f99f1cd36400aafc06fc73e1c5d9 (patch)
treef8c843cf75f2ad27616cd0ea7fd3a3e402ca0cd4
parentMake _make_unit_code more readable (diff)
Document the SNEKBOX_URL env var
-rw-r--r--README.md2
-rw-r--r--docker-compose.yml1
2 files changed, 3 insertions, 0 deletions
diff --git a/README.md b/README.md
index 3e38ef5..be0c8b9 100644
--- a/README.md
+++ b/README.md
@@ -8,6 +8,7 @@ To start working on forms-backend, you'll need few things:
2. Poetry
3. Docker and docker-compose (optional)
4. Running MongoDB instance (when not using Docker)
+5. Running [Snekbox](https://git.pydis.com/snekbox) instance (when not using Docker, optional)
### Running with Docker
The easiest way to run forms-backend is using Docker (and docker-compose).
@@ -29,6 +30,7 @@ Create a `.env` file with the same contents as the Docker section above and the
- `FRONTEND_URL`: Forms frontend URL.
- `DATABASE_URL`: MongoDB instance URI, in format `mongodb://(username):(password)@(database IP or domain):(port)`.
- `MONGO_DB`: MongoDB database name, defaults to `pydis_forms`.
+- `SNEKBOX_URL`: Snekbox evaluation endpoint.
#### Running
Simply run: `$ uvicorn --reload --host 0.0.0.0 --debug backend:app`.
diff --git a/docker-compose.yml b/docker-compose.yml
index fd2eee4..4e58ef7 100644
--- a/docker-compose.yml
+++ b/docker-compose.yml
@@ -32,6 +32,7 @@ services:
- .:/app:ro
environment:
- DATABASE_URL=mongodb://forms-backend:forms-backend@mongo:27017
+ - SNEKBOX_URL=http://snekbox:8060/eval
- OAUTH2_CLIENT_ID
- OAUTH2_CLIENT_SECRET
- ALLOWED_URL