I am running an empty mongodb instance in a docker desktop container using: docker run --name mongodb -d -p 64000:64000 mongo
Am running Compass v1.30.1 and attempting to connect to the mongodb running on localhost using the connection string: mongodb://localhost:64000
In the Compass UI, I receive the following visible error: connection <monitor> to 127.0.0.1:64000 closed
I have looked at the Compass log file and can see these entries:
{"t":{"$date":"2022-03-23T01:04:58.599Z"},"s":"I","c":"COMPASS-CONNECT-UI","id":1001000004,"ctx":"Connection UI","msg":"Initiating connection attempt"}
{"t":{"$date":"2022-03-23T01:04:58.602Z"},"s":"I","c":"COMPASS-DATA-SERVICE","id":1001000014,"ctx":"Connection 2","msg":"Connecting","attr":{"url":"mongodb://localhost:64000/?readPreference=primary&appname=MongoDB+Compass&directConnection=true&ssl=false"}}
{"t":{"$date":"2022-03-23T01:04:58.616Z"},"s":"I","c":"COMPASS-CONNECT","id":1001000010,"ctx":"Connect","msg":"Resolved SRV record","attr":{"from":"mongodb://localhost:64000/?readPreference=primary&appname=MongoDB+Compass&directConnection=true&ssl=false","to":"mongodb://localhost:64000/?readPreference=primary&appname=MongoDB+Compass&directConnection=true&ssl=false"}}
{"t":{"$date":"2022-03-23T01:04:58.618Z"},"s":"I","c":"COMPASS-CONNECT","id":1001000009,"ctx":"Connect","msg":"Initiating connection","attr":{"url":"mongodb://localhost:64000/?readPreference=primary&appname=MongoDB+Compass&directConnection=true&ssl=false","options":*{"monitorCommands":true}*}}
Also disabled my firewall temporarily, with no effect.
Any help appreciated. Thanks in advance.