-
-
Notifications
You must be signed in to change notification settings - Fork 10
/
docker-compose.yml
42 lines (39 loc) · 1.12 KB
/
docker-compose.yml
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
version: "3"
services:
postgres:
image: postgres:14.5
restart: always
environment:
- POSTGRES_USER=postgres
- POSTGRES_PASSWORD=postgres
ports:
- "5432:5432"
datamodel:
image: openclimatefix/nowcasting_datamodel
environment:
- DB_URL=postgresql://postgres:postgres@postgres:5432/postgres
- DB_URL_PV=postgresql://postgres:postgres@postgres:5432/postgres
depends_on:
- "postgres"
api:
build:
context: .
dockerfile: Dockerfile
# image: openclimatefix/nowcasting_api:0.1.7
container_name: nowcasting_api
command: bash -c "sleep 5
&& python script/fake_data.py
&& uvicorn src.main:app --host 0.0.0.0 --port 8000"
ports:
- 8000:8000
environment:
- DB_URL=postgresql://postgres:postgres@postgres:5432/postgres
- DB_URL_PV=postgresql://postgres:postgres@postgres:5432/postgres
- AUTH0_DOMAIN=nowcasting-dev.eu.auth0.com
- AUTH0_API_AUDIENCE=https://nowcasting-api-eu-auth0.com/
volumes:
- ./src/:/app/src
- ./script/:/app/script
depends_on:
- "postgres"
- "datamodel"