mirror of
https://github.com/gadgethd/ukmesh.git
synced 2026-12-06 11:14:26 +00:00
49 lines
1.6 KiB
YAML
49 lines
1.6 KiB
YAML
name: ukmesh-sample
|
|
services:
|
|
db:
|
|
image: timescale/timescaledb@sha256:22e8a5ae7aef121d1537afe946dd7cc5deeeb63ab36ce19849d671bd3b663509
|
|
container_name: ukmesh-sample-db
|
|
environment:
|
|
POSTGRES_USER: meshcore
|
|
POSTGRES_PASSWORD: meshcore
|
|
POSTGRES_DB: meshcore
|
|
ports: ["127.0.0.1:5433:5432"]
|
|
command: ["postgres", "-c", "shared_preload_libraries=timescaledb,pg_stat_statements", "-c", "max_parallel_workers_per_gather=0"]
|
|
volumes:
|
|
- sample-db:/var/lib/postgresql/data
|
|
- ../../backend/src/db/schema/base.sql:/docker-entrypoint-initdb.d/010-base.sql:ro
|
|
healthcheck:
|
|
test: ["CMD-SHELL", "pg_isready -h 127.0.0.1 -U meshcore -d meshcore"]
|
|
interval: 2s
|
|
timeout: 3s
|
|
retries: 60
|
|
cpus: 2
|
|
mem_limit: 2g
|
|
redis:
|
|
image: redis@sha256:8b81dd37ff027bec4e516d41acfbe9fe2460070dc6d4a4570a2ac5b9d59df065
|
|
container_name: ukmesh-sample-redis
|
|
ports: ["127.0.0.1:6380:6379"]
|
|
command: ["redis-server", "--save", "", "--appendonly", "no"]
|
|
healthcheck:
|
|
test: ["CMD", "redis-cli", "ping"]
|
|
interval: 2s
|
|
timeout: 3s
|
|
retries: 30
|
|
cpus: 1
|
|
mem_limit: 256m
|
|
mqtt:
|
|
image: eclipse-mosquitto@sha256:75d6662dee52c947dc9dd9c29f1d8d7ffef78ddaf38001caa09755681e8bbc98
|
|
container_name: ukmesh-sample-mqtt
|
|
ports: ["127.0.0.1:1884:1883", "127.0.0.1:9002:9001"]
|
|
volumes:
|
|
- ./mosquitto-test.conf:/mosquitto/config/mosquitto.conf:ro
|
|
healthcheck:
|
|
test: ["CMD-SHELL", "mosquitto_pub -h 127.0.0.1 -t local/health -m ready -q 1"]
|
|
interval: 2s
|
|
timeout: 3s
|
|
retries: 30
|
|
cpus: 1
|
|
mem_limit: 256m
|
|
volumes:
|
|
sample-db:
|