diff --git a/lib/charms/mongodb/v0/helpers.py b/lib/charms/mongodb/v0/helpers.py index ec7eaeaf4..d4c820aaa 100644 --- a/lib/charms/mongodb/v0/helpers.py +++ b/lib/charms/mongodb/v0/helpers.py @@ -91,8 +91,9 @@ def get_mongos_args(config: MongoDBConfiguration) -> str: # no need to add TLS since no network calls are used, since mongos is configured to listen # on local host cmd = [ - # mongos on config server side only runs on local host - "--bind_ip localhost", + # mongos on config server side should run on 0.0.0.0 so it can be accessed by other units + # in the sharded cluster + "--bind_ip 0.0.0.0", # todo figure out this one f"--configdb {config_server_uri}", # config server is already using 27017