[GIS] Setting up GeoServer – can’t reach server from remote (timeout)

geoserver

My target is to set up a WMS that can be displayed with OpenLayers.

Therefore I have set up GeoServer (2.10.1) on a Windows machine (Windows Server 2008 R2) and am successful to the point that I can reach the GeoServer interface on localhost:myport/geoserver including layer previews. On the machine itself I can also reach GeoServer via mydomain.com:myport/geoserver.

But I cannot reach it either from any other computer or via QGIS GeoServer Explorer plugin…

When I copy the layer preview URL to a browser on another machine, it ends up with a ERR_CONNECTION_TIMED_OUT.

I have tried setting the proxy URL in "Global Settings" to http://www.mydomain.com, but that didn't make a difference.

There is already a xampp installation running with Apache, Tomcat & MySQL. As Tomcat is already using port 8080, I am using another port for GeoServer.

Any ideas what I'm doing wrong?

Best Answer

Ok, so for other newbies to this topic:

First, I set up a proxy in my Apache (conf/httpd.conf) by enabling some modules and adding a VirtualHost section, according to How to proxy Geoserver through Apache in Windows.

Then, to enable SSL, I added another VirtualHost in conf\extra\httpd-vhosts.conf, according to http://documents.software.dell.com/desktop-workspace/4.0/advanced-setup-guide/deploying-a-reverse-proxy-server-with-apache:

<VirtualHost *:443>
    ServerName mydomain.com
    ServerAlias www.mydomain.com
    DocumentRoot "path/to/my/root"
    ErrorLog "logs/error-ssl.log"
    CustomLog "logs/access-ssl.log" common
    ProxyRequests Off
    ProxyPreserveHost Off

    <Location />
    Order allow,deny
    Allow from all
    </Location>

    SSLEngine on
    SSLCertificateFile "path/to/my/file"
    SSLCertificateKeyFile "path/to/my/file"
    ProxyPass /geoserver http://localhost:myport/geoserver
    ProxyPassReverse /geoserver http://localhost:myport/geoserver
    SSLProxyEngine On
</VirtualHost>