2023-09-29 08:51:48 +00:00
|
|
|
version: "3.9"
|
|
|
|
services:
|
|
|
|
|
|
|
|
devicehub-id-server:
|
|
|
|
init: true
|
2024-02-16 10:01:46 +00:00
|
|
|
image: dkr-dsg.ac.upc.edu/ereuse/devicehub:latest
|
2023-09-29 08:51:48 +00:00
|
|
|
environment:
|
|
|
|
- DB_USER=${DB_USER}
|
|
|
|
- DB_PASSWORD=${DB_PASSWORD}
|
|
|
|
- DB_HOST=postgres-id-server
|
|
|
|
- DB_DATABASE=${DB_DATABASE}
|
|
|
|
- HOST=${HOST}
|
|
|
|
- EMAIL_DEMO=${SERVER_ID_EMAIL_DEMO}
|
|
|
|
- PASSWORD_DEMO=${PASSWORD_DEMO}
|
|
|
|
- JWT_PASS=${JWT_PASS}
|
|
|
|
- SECRET_KEY=${SECRET_KEY}
|
|
|
|
- API_DLT=${API_DLT}
|
|
|
|
- API_RESOLVER=${API_RESOLVER}
|
|
|
|
- API_DLT_TOKEN=${API_DLT_TOKEN}
|
|
|
|
- DEVICEHUB_HOST=${SERVER_ID_DEVICEHUB_HOST}
|
|
|
|
- ID_FEDERATED=${SERVER_ID_FEDERATED}
|
|
|
|
- URL_MANUALS=${URL_MANUALS}
|
|
|
|
- ID_SERVICE=${SERVER_ID_SERVICE}
|
|
|
|
- AUTHORIZED_CLIENT_URL=${CLIENT_ID_DEVICEHUB_HOST}
|
|
|
|
- DPP_MODULE=y
|
|
|
|
- IMPORT_SNAPSHOTS=${IMPORT_SNAPSHOTS}
|
|
|
|
ports:
|
|
|
|
- 5000:5000
|
|
|
|
volumes:
|
|
|
|
- ${SNAPSHOTS_PATH:-./examples/snapshots}:/mnt/snapshots:ro
|
|
|
|
- shared:/shared:rw
|
2023-10-24 06:43:27 +00:00
|
|
|
- app_id_server:/opt/devicehub:rw
|
2023-09-29 08:51:48 +00:00
|
|
|
|
|
|
|
postgres-id-server:
|
2024-02-16 10:01:46 +00:00
|
|
|
image: dkr-dsg.ac.upc.edu/ereuse/postgres:latest
|
2023-09-29 08:51:48 +00:00
|
|
|
# 4. To create the database.
|
|
|
|
# 5. Give permissions to the corresponding users in the database.
|
|
|
|
# extra src https://github.com/docker-library/docs/blob/master/postgres/README.md#environment-variables
|
|
|
|
environment:
|
|
|
|
- POSTGRES_PASSWORD=${DB_PASSWORD}
|
|
|
|
- POSTGRES_USER=${DB_USER}
|
|
|
|
- POSTGRES_DB=${DB_DATABASE}
|
|
|
|
# DEBUG
|
|
|
|
#ports:
|
|
|
|
# - 5432:5432
|
|
|
|
# TODO persistence
|
|
|
|
#volumes:
|
|
|
|
# - pg_data:/var/lib/postgresql/data
|
|
|
|
|
|
|
|
devicehub-id-client:
|
|
|
|
init: true
|
2024-02-16 10:01:46 +00:00
|
|
|
image: dkr-dsg.ac.upc.edu/ereuse/devicehub:latest
|
2023-09-29 08:51:48 +00:00
|
|
|
environment:
|
|
|
|
- DB_USER=${DB_USER}
|
|
|
|
- DB_PASSWORD=${DB_PASSWORD}
|
|
|
|
- DB_HOST=postgres-id-client
|
|
|
|
- DB_DATABASE=${DB_DATABASE}
|
|
|
|
- HOST=${HOST}
|
|
|
|
- EMAIL_DEMO=${CLIENT_ID_EMAIL_DEMO}
|
|
|
|
- PASSWORD_DEMO=${PASSWORD_DEMO}
|
|
|
|
- JWT_PASS=${JWT_PASS}
|
|
|
|
- SECRET_KEY=${SECRET_KEY}
|
|
|
|
- API_DLT=${API_DLT}
|
|
|
|
- API_RESOLVER=${API_RESOLVER}
|
|
|
|
- API_DLT_TOKEN=${API_DLT_TOKEN}
|
|
|
|
- DEVICEHUB_HOST=${CLIENT_ID_DEVICEHUB_HOST}
|
|
|
|
- SERVER_ID_HOST=${SERVER_ID_DEVICEHUB_HOST}
|
|
|
|
- ID_FEDERATED=${CLIENT_ID_FEDERATED}
|
|
|
|
- URL_MANUALS=${URL_MANUALS}
|
|
|
|
- ID_SERVICE=${CLIENT_ID_SERVICE}
|
|
|
|
- DPP_MODULE=y
|
|
|
|
- IMPORT_SNAPSHOTS=${IMPORT_SNAPSHOTS}
|
|
|
|
ports:
|
|
|
|
- 5001:5000
|
|
|
|
volumes:
|
|
|
|
- ${SNAPSHOTS_PATH:-./examples/snapshots}:/mnt/snapshots:ro
|
|
|
|
- shared:/shared:ro
|
2023-10-24 06:43:27 +00:00
|
|
|
- app_id_client:/opt/devicehub:rw
|
2023-09-29 08:51:48 +00:00
|
|
|
|
|
|
|
postgres-id-client:
|
2024-02-16 10:01:46 +00:00
|
|
|
image: dkr-dsg.ac.upc.edu/ereuse/postgres:latest
|
2023-09-29 08:51:48 +00:00
|
|
|
# 4. To create the database.
|
|
|
|
# 5. Give permissions to the corresponding users in the database.
|
|
|
|
# extra src https://github.com/docker-library/docs/blob/master/postgres/README.md#environment-variables
|
|
|
|
environment:
|
|
|
|
- POSTGRES_PASSWORD=${DB_PASSWORD}
|
|
|
|
- POSTGRES_USER=${DB_USER}
|
|
|
|
- POSTGRES_DB=${DB_DATABASE}
|
|
|
|
# DEBUG
|
|
|
|
#ports:
|
|
|
|
# - 5432:5432
|
|
|
|
# TODO persistence
|
|
|
|
#volumes:
|
|
|
|
# - pg_data:/var/lib/postgresql/data
|
|
|
|
|
|
|
|
|
|
|
|
# TODO https://testdriven.io/blog/dockerizing-django-with-postgres-gunicorn-and-nginx/
|
|
|
|
#nginx
|
|
|
|
|
|
|
|
volumes:
|
|
|
|
shared:
|
2023-10-24 06:43:27 +00:00
|
|
|
app_id_client:
|
|
|
|
app_id_server:
|