name: notesnook-external-mongodb-infra services: notesnook-mongodb: image: mongo:7.0.12 hostname: notesnook-mongodb ports: - 27017:27017 volumes: - dbdata:/data/db networks: - notesnook-shared command: --replSet rs0 --bind_ip_all healthcheck: test: echo 'try { rs.status() } catch (err) { rs.initiate() }; db.runCommand("ping").ok' | mongosh mongodb://localhost:27017 --quiet interval: 40s timeout: 30s retries: 3 start_period: 60s networks: notesnook-shared: name: notesnook-shared volumes: dbdata: