forked from Ivasoft/geovisio-website
80 lines
2.0 KiB
YAML
80 lines
2.0 KiB
YAML
services:
|
|
api:
|
|
image: geovisio/api:develop
|
|
command: api
|
|
restart: always
|
|
ports:
|
|
- 5000:5000
|
|
depends_on:
|
|
db:
|
|
condition: service_healthy
|
|
auth:
|
|
condition: service_healthy
|
|
environment:
|
|
DB_URL: postgres://gvs:gvspwd@db/geovisio
|
|
PICTURE_PROCESS_THREADS_LIMIT: 2
|
|
PICTURE_PROCESS_DERIVATES_STRATEGY: ON_DEMAND
|
|
API_FORCE_AUTH_ON_UPLOAD: 'true'
|
|
OAUTH_CLIENT_ID: geovisio
|
|
OAUTH_CLIENT_SECRET: what_a_secret
|
|
OAUTH_OIDC_URL: http://localhost:8183/realms/geovisio
|
|
OAUTH_PROVIDER: oidc
|
|
FLASK_SECRET_KEY: a_very_secret_key_never_to_be_used_in_production
|
|
healthcheck:
|
|
test: python -c "import requests; requests.get('http://localhost:5000/api').raise_for_status()"
|
|
interval: 5s
|
|
timeout: 5s
|
|
retries: 10
|
|
extra_hosts:
|
|
- 'localhost:host-gateway'
|
|
|
|
networks:
|
|
db: {}
|
|
geovisio:
|
|
aliases:
|
|
- api.localtest.me
|
|
|
|
db:
|
|
image: postgis/postgis:13-3.2
|
|
environment:
|
|
- POSTGRES_USER=gvs
|
|
- POSTGRES_PASSWORD=gvspwd
|
|
- POSTGRES_DB=geovisio
|
|
healthcheck:
|
|
test: pg_isready -q -d $$POSTGRES_DB -U $$POSTGRES_USER
|
|
interval: 5s
|
|
timeout: 5s
|
|
retries: 5
|
|
networks:
|
|
db: {}
|
|
|
|
auth:
|
|
command: start-dev --import-realm
|
|
environment:
|
|
GEOVISIO_BASE_URL: http://localhost:5000
|
|
GEOVISIO_CLIENT_SECRET: what_a_secret
|
|
KEYCLOAK_ADMIN: admin
|
|
KEYCLOAK_ADMIN_PASSWORD: password
|
|
KEYCLOAK_FRONTEND_URL: http://localhost:5000/api/auth/login
|
|
KC_HTTP_PORT: 8183
|
|
ports:
|
|
- '8183:8183'
|
|
healthcheck:
|
|
test: curl --fail http://localhost:8183/realms/geovisio
|
|
timeout: 5s
|
|
interval: 2s
|
|
retries: 20
|
|
start_period: 10s
|
|
image: quay.io/keycloak/keycloak:20.0.1
|
|
volumes:
|
|
- ./keycloak-realm.json:/opt/keycloak/data/import/geovisio_realm.json
|
|
|
|
networks:
|
|
geovisio:
|
|
aliases:
|
|
- keycloak.localtest.me
|
|
|
|
networks:
|
|
db: {}
|
|
geovisio: {}
|