Compare commits

...
Author SHA1 Message Date
moritz 0155cd47e0 chore: update image tags 2026-09-28 19:00:59 +02:00
moritz 9926c5a406 fix replica set 2026-09-28 18:59:27 +02:00
+21 -15
View File
@@ -1,27 +1,33 @@
version: "3.8"
services:
db:
image: mongo:8.3
image: mongo:7.0
hostname: db
environment:
- LOGO_IMG_URL
- LOGO_LINK_URL
command: >
sh -c "
mongod --oplogSize 128 --replSet rs0 --quiet --bind_ip_all &
until mongosh --eval 'rs.initiate()' > /dev/null 2>&1; do
sleep 2
done;
wait"
command:
- bash
- -c
- |
(
until mongosh --quiet --eval 'try { rs.status().ok } catch (e) { rs.initiate({_id: "rs0", members: [{_id: 0, host: "db:27017"}]}).ok }' 2>/dev/null | grep -q 1; do
sleep 2
done
echo "[init] replica set rs0 ready"
) &
exec mongod --replSet rs0 --bind_ip_all --oplogSize 128 --quiet
volumes:
- wekan-db:/data/db
networks:
- internal
healthcheck:
test: echo 'db.runCommand("ping").ok' | mongosh localhost:27017/test --quiet
interval: 30s
test: ["CMD", "mongosh", "--host", "127.0.0.1", "--port", "27017", "--quiet", "--eval", "try { quit(rs.status().ok === 1 && db.hello().isWritablePrimary ? 0 : 1) } catch (e) { quit(1) }"]
interval: 10s
timeout: 10s
retries: 10
start_period: 1m
retries: 30
start_period: 5m
stop_grace_period: 1m
deploy:
labels:
backupbot.backup: "${ENABLE_BACKUPS:-true}"
@@ -30,10 +36,10 @@ services:
backupbot.restore.post-hook: "mongorestore --drop --archive=/data/db/wekan.db"
app:
image: quay.io/wekan/wekan:v10.79
image: quay.io/wekan/wekan:v12.08
environment:
- METEOR_REACTIVITY_ORDER=changeStreams,oplog,polling
- MONGO_URL=mongodb://db:27017/wekan
- MONGO_URL=mongodb://db:27017/wekan?replicaSet=rs0
- MONGO_OPLOG_URL=mongodb://db:27017/local?replicaSet=rs0
- NODE_OPTIONS="--max_old_space_size=4096"
- DOMAIN
@@ -76,7 +82,7 @@ services:
interval: 30s
timeout: 10s
retries: 10
start_period: 3m
start_period: 5m
secrets:
- oauth2_secret
configs: