forked from denostr-lab/denostr
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.local.yml
83 lines (81 loc) · 1.94 KB
/
docker-compose.local.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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
services:
denostr:
build: .
container_name: denostr
environment:
RELAY_PORT: 8008
NOSTR_CONFIG_DIR: /app/.nostr
SECRET: ${SECRET}
MONGO_URI: "mongodb://denostr-db:27017/denostr?replicaSet=rs0"
MONGO_MIN_POOL_SIZE: 3
MONGO_MAX_POOL_SIZE: 8
DEBUG: "*"
user: deno:deno
volumes:
- ${PWD}/.nostr:/app/.nostr
ports:
- 8008:8008
depends_on:
denostr-db:
condition: service_healthy
denostr-db-rs-init:
condition: service_completed_successfully
restart: on-failure
networks:
default:
denostr-db:
image: mongo:5.0
container_name: denostr-db
networks:
default:
restart: always
ports:
- '27017:27017'
volumes:
- db:/data/db
entrypoint: ["mongod", "--bind_ip_all", "--replSet", "rs0"]
healthcheck:
test: echo 'db.runCommand("ping").ok' | mongo --host 127.0.0.1 --port 27017 --quiet 1
interval: 5s
timeout: 5s
retries: 3
start_period: 5s
denostr-db-rs-init:
image: mongo:5.0
container_name: denostr-db-rs-init
environment:
MONGO_URI: mongodb://denostr-db:27017/
command: bash /data/mongo-rs-init.sh
volumes:
- ${PWD}/.docker/mongo-rs-init.local.sh:/data/mongo-rs-init.sh
networks:
default:
depends_on:
denostr-db:
condition: service_healthy
denostr-db-express:
image: mongo-express:latest
container_name: denostr-db-express
environment:
ME_CONFIG_OPTIONS_EDITORTHEME: ambiance
ME_CONFIG_MONGODB_SERVER: denostr-db
ME_CONFIG_MONGODB_PORT: 27017
restart: always
ports:
- '8081:8081'
networks:
default:
depends_on:
denostr-db:
condition: service_healthy
denostr-db-rs-init:
condition: service_completed_successfully
networks:
default:
name: denostr
ipam:
driver: default
config:
- subnet: 10.10.10.0/24
volumes:
db: