Configuring gitpod for MongoDB and Compass

I am trying to point my compass to my gitpod url from the (gp url 27017) but I do not know how to set up the port as compass keeps loading but does not connect to the database. Noting that compass is running in my local machine is there a way to run it in gitpod?

If mongod is running you should see in the bottom right corner the ports. If you click on it you can make the port public. Compass should then be able to connect to the public address.