From f32d3b6fa049a51f6fb87a77f6a0dbab6580e7ed Mon Sep 17 00:00:00 2001 From: Turkidev <114973795+Turkidev@users.noreply.github.com> Date: Thu, 7 Mar 2024 19:49:37 +0300 Subject: [PATCH] Update egg-mongo-d-b7.json replacing the 127.0.0.1 with {{SERVER_IP}} to fix when the node has more than 1 ip --- database/nosql/mongodb/egg-mongo-d-b7.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/database/nosql/mongodb/egg-mongo-d-b7.json b/database/nosql/mongodb/egg-mongo-d-b7.json index c00f8a90..d28382b8 100644 --- a/database/nosql/mongodb/egg-mongo-d-b7.json +++ b/database/nosql/mongodb/egg-mongo-d-b7.json @@ -13,7 +13,7 @@ "MongoDB_7": "ghcr.io\/parkervcp\/yolks:mongodb_7" }, "file_denylist": [], - "startup": "mongod --fork --dbpath \/home\/container\/mongodb\/ --port ${SERVER_PORT} --bind_ip 0.0.0.0 --logpath \/home\/container\/logs\/mongo.log -f \/home\/container\/mongod.conf; until nc -z -v -w5 127.0.0.1 ${SERVER_PORT}; do echo 'Waiting for mongodb connection...'; sleep 5; done; mongosh --username ${MONGO_USER} --password ${MONGO_USER_PASS} --host 127.0.0.1:${SERVER_PORT} && mongosh --eval \"db.getSiblingDB('admin').shutdownServer()\" 127.0.0.1:${SERVER_PORT}", + "startup": "mongod --fork --dbpath \/home\/container\/mongodb\/ --port ${SERVER_PORT} --bind_ip 0.0.0.0 --logpath \/home\/container\/logs\/mongo.log -f \/home\/container\/mongod.conf; until nc -z -v -w5 {{SERVER_IP}} ${SERVER_PORT}; do echo 'Waiting for mongodb connection...'; sleep 5; done; mongosh --username ${MONGO_USER} --password ${MONGO_USER_PASS} --host {{SERVER_IP}}:${SERVER_PORT} && mongosh --eval \"db.getSiblingDB('admin').shutdownServer()\" {{SERVER_IP}}:${SERVER_PORT}", "config": { "files": "{\r\n \"mongod.conf\": {\r\n \"parser\": \"file\",\r\n \"find\": {\r\n \"#security:\": \"security: \\r\\n authorization: \\\"enabled\\\"\"\r\n }\r\n }\r\n}", "startup": "{\r\n \"done\": \"child process started successfully\"\r\n}", @@ -49,4 +49,4 @@ "field_type": "text" } ] -} \ No newline at end of file +}