I am developing an application that uses MongoDB Atlas as a database. Currently, my application is hosted on a server, but we are having trouble accessing the database because ports 27015 to 27017 used by MongoDB Atlas are closed on our hosting server.
To open these ports, the hosting server asks for the IP address of MongoDB Atlas to be whitelisted, but I don’t know the specific IP of the MongoDB Atlas cluster that I am using. Since MongoDB Atlas uses a DNS-based connection and does not provide a static IP, I cannot get the IP address directly.
Is there a solution or steps that I can do to allow access to MongoDB Atlas without requiring a specific IP address? Can I use the hostname to whitelist or is there another way I can try?
Thank you for your attention and help