2023-04-06 09:47:00 +00:00
|
|
|
version: '3.2'
|
|
|
|
|
|
|
|
services:
|
|
|
|
# Builds and serves the MobyMask react-app
|
|
|
|
mobymask-app:
|
|
|
|
image: cerc/mobymask-ui:local
|
|
|
|
env_file:
|
|
|
|
- ../config/watcher-mobymask-v2/mobymask-params.env
|
2023-04-11 10:51:03 +00:00
|
|
|
environment:
|
|
|
|
CERC_SCRIPT_DEBUG: ${CERC_SCRIPT_DEBUG}
|
|
|
|
CERC_CHAIN_ID: ${CERC_CHAIN_ID}
|
|
|
|
CERC_DEPLOYED_CONTRACT: ${CERC_DEPLOYED_CONTRACT}
|
|
|
|
CERC_APP_WATCHER_URL: ${CERC_APP_WATCHER_URL}
|
|
|
|
CERC_RELAY_NODES: ${CERC_RELAY_NODES}
|
2023-04-06 09:47:00 +00:00
|
|
|
# Waits for watcher server to be up before app build
|
|
|
|
# Required when running with watcher stack to get deployed contract address
|
|
|
|
command:
|
|
|
|
- sh
|
|
|
|
- -c
|
2023-04-11 10:51:03 +00:00
|
|
|
- ./wait-for-it.sh -h ${CERC_WATCHER_HOST:-$${DEFAULT_CERC_WATCHER_HOST}} -p ${CERC_WATCHER_PORT:-$${DEFAULT_CERC_WATCHER_PORT}} -s -t 0 -- ./mobymask-app-start.sh
|
2023-04-06 09:47:00 +00:00
|
|
|
volumes:
|
|
|
|
- ../config/wait-for-it.sh:/app/wait-for-it.sh
|
|
|
|
- ../config/watcher-mobymask-v2/mobymask-app-config.json:/app/src/mobymask-app-config.json
|
|
|
|
- ../config/watcher-mobymask-v2/mobymask-app-start.sh:/app/mobymask-app-start.sh
|
|
|
|
- mobymask_deployment:/server
|
|
|
|
ports:
|
|
|
|
- "0.0.0.0:3002:3000"
|
|
|
|
healthcheck:
|
|
|
|
test: ["CMD", "nc", "-v", "localhost", "3000"]
|
|
|
|
interval: 20s
|
|
|
|
timeout: 5s
|
|
|
|
retries: 15
|
|
|
|
start_period: 10s
|
|
|
|
shm_size: '1GB'
|
2023-04-11 10:51:03 +00:00
|
|
|
extra_hosts:
|
|
|
|
- "host.docker.internal:host-gateway"
|
2023-04-06 09:47:00 +00:00
|
|
|
|
|
|
|
volumes:
|
|
|
|
mobymask_deployment:
|