Gitlab pages on an omnibus server that is linked through an ssh tunnel to the public network

Is it possible to connect the gitlab pages through an SSH tunnel and reach them from anywhere? and if so, how do I need to configure that?

My setup is a gitlab server on the local network. There is an SSH tunnel from that server to an external server that forwards all requests from the internet through the tunnel to the local server.

What IP address and URL do I need to configure in the gitlab.rb configuration file?

When I want to create a new domain in the repo settings–>pages–>new page domain, the error 500 appears.

I’m really stuck here and don’t know how to proceed.

Thanks!