[Geoserver-users] Geoserver and NAT

Hello to all,

I have a geoserver installation working behind a NAT, and the necessary ports has been
mapped to apache and geoserver (8081—>80 and 8082—>8080).

The WMS layers works fine, however an error occurs with the WFS layers saying <urlopen error (111, ‘Connection refused’)>.

Are there any ports other than the ones mentioned above that must be mapped to geoserver for wfs to work.

My web files are in /var/www. When I copy these to the data_dir/www folder inside the geoserver wfs works.
(The wfs url must be changed from :8082:/geoserver/wfs to /geoserver/wfs)

Thanks in advance,

Regards,
Indika


Hi Indika,

It is not exactly clear... what client are you using to access the GeoServer WFS? You say coping your web files over to data_dir/www makes things work? Does this mean you are using an OpenLayers map to access? Or perhaps an html form? Some more info should help us solve the issue.

-Justin

Indika Tantrigoda wrote:

Hello to all,

I have a geoserver installation working behind a NAT, and the necessary ports has been
mapped to apache and geoserver (8081--->80 and 8082--->8080).

The WMS layers works fine, however an error occurs with the WFS layers saying <urlopen error (111, 'Connection refused')>.

Are there any ports other than the ones mentioned above that must be mapped to geoserver for wfs to work.

My web files are in /var/www. When I copy these to the data_dir/www folder inside the geoserver wfs works.
(The wfs url must be changed from <ip-address>:8082:/geoserver/wfs to /geoserver/wfs)

Thanks in advance,

Regards,
Indika

------------------------------------------------------------------------

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/

------------------------------------------------------------------------

_______________________________________________
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users

--
Justin Deoliveira
OpenGeo - http://opengeo.org
Enterprise support for open source geospatial.

Hi Justin,

Yes, I am using OpenLayers as the client to view the maps.

As I mentioned earlier, the geoserver box is behind a server which performs NAT.
Port 8081 on the NAT machine has been mapped to port and 80 on the geoserver box and
port 8082 on the NAT machine has been mapped to port 8080 on the geoserver box.

The web files (php, html) are stored in /var/www folder.

When I access the web files like http://:8081/mymap.php only the WMS layers
are displayed. While the response to the wfs layer request was <urlopen error (111, ‘Connection refused’)>.
I access geoserver in my javascript as http://:8082/wfs.

Therefore I changed the request parameters on OpenLayers so that the wfs requests would directly access the geoserver box
via the Intranet, (without going through the NAT server) which showed the wfs layers.

Therefore I assumed that some ports that are needed by wfs/geoserver are blocked by the NAT machine.

The only way that I was able to display the wfs layers via the Internet, was by placing my web files in the geoserver/data_dir/www directory.

I have added my ip adress to the proxy.cgi which is requried by OpenLayers.

I would like to have the web files in the /var/www folder. Therefore would I need to map any other ports in the NAT server to the geoserver box, or perform any other configurations to achive this. I am using geoserver 1.6.3.

Thanks,

Regards,

Indika

2008/12/1 Justin Deoliveira <jdeolive@anonymised.com>

Hi Indika,

It is not exactly clear… what client are you using to access the GeoServer WFS? You say coping your web files over to data_dir/www makes things work? Does this mean you are using an OpenLayers map to access? Or perhaps an html form? Some more info should help us solve the issue.

-Justin

Indika Tantrigoda wrote:

Hello to all,

I have a geoserver installation working behind a NAT, and the necessary ports has been
mapped to apache and geoserver (8081—>80 and 8082—>8080).

The WMS layers works fine, however an error occurs with the WFS layers saying <urlopen error (111, ‘Connection refused’)>.

Are there any ports other than the ones mentioned above that must be mapped to geoserver for wfs to work.

My web files are in /var/www. When I copy these to the data_dir/www folder inside the geoserver wfs works.
(The wfs url must be changed from :8082:/geoserver/wfs to /geoserver/wfs)

Thanks in advance,

Regards,
Indika



This SF.Net email is sponsored by the Moblin Your Move Developer’s challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/



Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users


Justin Deoliveira
OpenGeo - http://opengeo.org
Enterprise support for open source geospatial.

Hi Indika,

It sounds like you are running afoul of JavaScript's 'same-origin' policy, which requires that XMLHttpRequests made in JavaScript be made to the same host and port as the page was served from. You will need to configure Apache to proxy GeoServer so that clients see the same port number for GeoServer and your static files hosted via Apache. We have a page on the wiki about this:
http://geoserver.org/display/GEOSDOC/How+to+proxy+Jetty+through+Apache+on+port+80

Despite the title, this applies to any servlet container.

Hope this helps,
David Winslow

Indika Tantrigoda wrote:

Hi Justin,

Yes, I am using OpenLayers as the client to view the maps.

As I mentioned earlier, the geoserver box is behind a server which performs NAT.
Port 8081 on the NAT machine has been mapped to port and 80 on the geoserver box and
port 8082 on the NAT machine has been mapped to port 8080 on the geoserver box.

The web files (php, html) are stored in /var/www folder.

When I access the web files like http://<ip-address>:8081/mymap.php only the WMS layers
are displayed. While the response to the wfs layer request was <urlopen error (111, 'Connection refused')>.
I access geoserver in my javascript as http://<ip-address>:8082/wfs.

Therefore I changed the request parameters on OpenLayers so that the wfs requests would directly access the geoserver box
via the Intranet, (without going through the NAT server) which showed the wfs layers.

Therefore I assumed that some ports that are needed by wfs/geoserver are blocked by the NAT machine.

The only way that I was able to display the wfs layers via the Internet, was by placing my web files in the geoserver/data_dir/www directory.

I have added my ip adress to the proxy.cgi which is requried by OpenLayers.

I would like to have the web files in the /var/www folder. Therefore would I need to map any other ports in the NAT server to the geoserver box, or perform any other configurations to achive this. I am using geoserver 1.6.3. <http://1.6.3.>

Thanks,

Regards,

Indika

2008/12/1 Justin Deoliveira <jdeolive@anonymised.com <mailto:jdeolive@anonymised.com>>

    Hi Indika,

    It is not exactly clear... what client are you using to access the
    GeoServer WFS? You say coping your web files over to data_dir/www
    makes things work? Does this mean you are using an OpenLayers map
    to access? Or perhaps an html form? Some more info should help us
    solve the issue.

    -Justin

    Indika Tantrigoda wrote:

        Hello to all,

        I have a geoserver installation working behind a NAT, and the
        necessary ports has been
        mapped to apache and geoserver (8081--->80 and 8082--->8080).

        The WMS layers works fine, however an error occurs with the
        WFS layers saying <urlopen error (111, 'Connection refused')>.

        Are there any ports other than the ones mentioned above that
        must be mapped to geoserver for wfs to work.

        My web files are in /var/www. When I copy these to the
        data_dir/www folder inside the geoserver wfs works.
        (The wfs url must be changed from
        <ip-address>:8082:/geoserver/wfs to /geoserver/wfs)

        Thanks in advance,

        Regards,
        Indika

        ------------------------------------------------------------------------

        -------------------------------------------------------------------------
        This SF.Net email is sponsored by the Moblin Your Move
        Developer's challenge
        Build the coolest Linux based applications with Moblin SDK &
        win great prizes
        Grand prize is a trip for two to an Open Source event anywhere
        in the world
        http://moblin-contest.org/redirect.php?banner_id=100&url=/
        <http://moblin-contest.org/redirect.php?banner_id=100&url=/&gt;

        ------------------------------------------------------------------------

        _______________________________________________
        Geoserver-users mailing list
        Geoserver-users@lists.sourceforge.net
        <mailto:Geoserver-users@lists.sourceforge.net>
        https://lists.sourceforge.net/lists/listinfo/geoserver-users

    -- Justin Deoliveira
    OpenGeo - http://opengeo.org
    Enterprise support for open source geospatial.

------------------------------------------------------------------------

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
------------------------------------------------------------------------

_______________________________________________
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users
  

Hi,

Thanks for the link. I tried following the given instructions but still the wfs layers are not visible.

As I mentioned earlier when I pass the the geoserver location as 172.16.11.14:8080 in OpenLayers and
keeping the web files in /var/www folder the wfs layers are visible.

It seems that the ‘same-origin’ policy is not violated when accessing using the local network, but is violated when
the IP address is changed to the NAT server, which has a public IP address, and the wfs request is sent via the Internet.

Any Ideas how I can work around this ?

Thanks

Regards,
Indika

2008/12/1 David Winslow <dwinslow@anonymised.com>

Hi Indika,

It sounds like you are running afoul of JavaScript’s ‘same-origin’ policy, which requires that XMLHttpRequests made in JavaScript be made to the same host and port as the page was served from. You will need to configure Apache to proxy GeoServer so that clients see the same port number for GeoServer and your static files hosted via Apache. We have a page on the wiki about this:
http://geoserver.org/display/GEOSDOC/How+to+proxy+Jetty+through+Apache+on+port+80

Despite the title, this applies to any servlet container.

Hope this helps,
David Winslow

Indika Tantrigoda wrote:

Hi Justin,

Yes, I am using OpenLayers as the client to view the maps.

As I mentioned earlier, the geoserver box is behind a server which performs NAT.
Port 8081 on the NAT machine has been mapped to port and 80 on the geoserver box and
port 8082 on the NAT machine has been mapped to port 8080 on the geoserver box.

The web files (php, html) are stored in /var/www folder.

When I access the web files like http://:8081/mymap.php only the WMS layers
are displayed. While the response to the wfs layer request was <urlopen error (111, ‘Connection refused’)>.
I access geoserver in my javascript as http://:8082/wfs.

Therefore I changed the request parameters on OpenLayers so that the wfs requests would directly access the geoserver box
via the Intranet, (without going through the NAT server) which showed the wfs layers.

Therefore I assumed that some ports that are needed by wfs/geoserver are blocked by the NAT machine.

The only way that I was able to display the wfs layers via the Internet, was by placing my web files in the geoserver/data_dir/www directory.

I have added my ip adress to the proxy.cgi which is requried by OpenLayers.

I would like to have the web files in the /var/www folder. Therefore would I need to map any other ports in the NAT server to the geoserver box, or perform any other configurations to achive this. I am using geoserver 1.6.3. <http://1.6.3.>

Thanks,

Regards,

Indika

2008/12/1 Justin Deoliveira <jdeolive@anonymised.com mailto:[jdeolive@anonymised.com](mailto:jdeolive@anonymised.com)>

Hi Indika,

It is not exactly clear… what client are you using to access the
GeoServer WFS? You say coping your web files over to data_dir/www
makes things work? Does this mean you are using an OpenLayers map
to access? Or perhaps an html form? Some more info should help us
solve the issue.

-Justin

Indika Tantrigoda wrote:

Hello to all,

I have a geoserver installation working behind a NAT, and the
necessary ports has been
mapped to apache and geoserver (8081—>80 and 8082—>8080).

The WMS layers works fine, however an error occurs with the
WFS layers saying <urlopen error (111, ‘Connection refused’)>.

Are there any ports other than the ones mentioned above that
must be mapped to geoserver for wfs to work.

My web files are in /var/www. When I copy these to the
data_dir/www folder inside the geoserver wfs works.
(The wfs url must be changed from
:8082:/geoserver/wfs to /geoserver/wfs)

Thanks in advance,

Regards,
Indika



This SF.Net email is sponsored by the Moblin Your Move
Developer’s challenge
Build the coolest Linux based applications with Moblin SDK &
win great prizes
Grand prize is a trip for two to an Open Source event anywhere
in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
<http://moblin-contest.org/redirect.php?banner_id=100&url=/>



Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net

mailto:[Geoserver-users@lists.sourceforge.net](mailto:Geoserver-users@lists.sourceforge.net)

https://lists.sourceforge.net/lists/listinfo/geoserver-users

– Justin Deoliveira
OpenGeo - http://opengeo.org
Enterprise support for open source geospatial.



This SF.Net email is sponsored by the Moblin Your Move Developer’s challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/


Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users

The ProxyPreserveHost directive is essential and possibly causing you
the problems.

Are you sure your NAT-setup is also setup to work on your local
network? You can work around
this by providing local DNS-entries or using the HOSTS file on your system.

Kind regards,

Pieter

Hi,

The NAT setup is not setup to work on the local network. Only requests coming
from the Internet pass through the NAT. Also I dont have access to the DNS machine.
So I am kinda stuck.

Keeping the web files in /geoserver/data_dir/www seems to be a temporary solution,
however in the long run I would prefer to have them in /var/www.

I’ll keep trying to find a work around for this. Maybe going through the server logs would shed some
light. However I dont plan to keep the geoserver box behind a NAT server in the long run.

Also can anyone point me to any services that offer geoserver and postgres hosting facilities.

Thanks for all the help.

Regards,
Indika

2008/12/2 Pieter Jansen <pjansen@anonymised.com>

The ProxyPreserveHost directive is essential and possibly causing you
the problems.

Are you sure your NAT-setup is also setup to work on your local
network? You can work around
this by providing local DNS-entries or using the HOSTS file on your system.

Kind regards,

Pieter

Indika Tantrigoda wrote:

Hi,

The NAT setup is not setup to work on the local network. Only requests coming
from the Internet pass through the NAT. Also I dont have access to the DNS machine.
So I am kinda stuck.

Keeping the web files in /geoserver/data_dir/www seems to be a temporary solution,
however in the long run I would prefer to have them in /var/www.

I'll keep trying to find a work around for this. Maybe going through the server logs would shed some
light. However I dont plan to keep the geoserver box behind a NAT server in the long run.

Also can anyone point me to any services that offer geoserver and postgres hosting facilities.

Thanks for all the help.

Regards,
Indika

Not sure I follow on all this, but what we do at OpenGeo is exactly what I would do in your case. David linked to it before [1].

The method doesn't care about NAT, just make sure you use URLs like "/geoserver/wfs" or "geoserver/wfs" when doing WFS queries. Do not tell the WFS client to use http://something:8080 , because if you accessed the JavaScript through :80 then it will treat :8080 as a different host.

So this means you can put your HTML and JavaScript in /var/www , and Apache will pretend like GeoServer lives in
/var/www/geoserver, so http://somehostname/geoserver will work, and the external http://someotherhostname:8081/geoserver will also work automatically.

Just make sure the path you are proxying is the same as the servlet context, i.e. don't proxy
http://yourhostname/some_other_name to http://localhost:8080/geoserver

Hope that helps, make sure you have the proxy working internally before you start worrying about the NAT.

Regarding hosting: I don't know of any GeoServer / Postgresql specific hosting facilities. Personally I use hetzner.de a lot (49 Euros per month for the cheapest dedicated box, if you're comfy with Linux). You can also try Amazon EC2 or other VPSs for a small installation, but unfortunately I have no specific advice to offer.

-Arne

1: http://geoserver.org/display/GEOSDOC/How+to+proxy+Jetty+through+Apache+on+port+80

--
Arne Kepp
OpenGeo - http://opengeo.org
Expert service straight from the developers

Hi Arne,

Thanks for the info. I think I messed my configurations in setting up the proxy.

Can u explain a little more on

Just make sure the path you are proxying is the same as the servlet context, i.e. don’t proxy
http://yourhostname/some_other_name to http://localhost:8080/geoserver

Thanks,

Regards,
Indika

2008/12/3 Arne Kepp <ak@anonymised.com>

Indika Tantrigoda wrote:

Hi,

The NAT setup is not setup to work on the local network. Only requests coming
from the Internet pass through the NAT. Also I dont have access to the DNS machine.
So I am kinda stuck.

Keeping the web files in /geoserver/data_dir/www seems to be a temporary solution,
however in the long run I would prefer to have them in /var/www.

I’ll keep trying to find a work around for this. Maybe going through the server logs would shed some
light. However I dont plan to keep the geoserver box behind a NAT server in the long run.

Also can anyone point me to any services that offer geoserver and postgres hosting facilities.

Thanks for all the help.

Regards,
Indika

Not sure I follow on all this, but what we do at OpenGeo is exactly what I would do in your case. David linked to it before [1].

The method doesn’t care about NAT, just make sure you use URLs like “/geoserver/wfs” or “geoserver/wfs” when doing WFS queries. Do not tell the WFS client to use http://something:8080 , because if you accessed the JavaScript through :80 then it will treat :8080 as a different host.

So this means you can put your HTML and JavaScript in /var/www , and Apache will pretend like GeoServer lives in
/var/www/geoserver, so http://somehostname/geoserver will work, and the external http://someotherhostname:8081/geoserver will also work automatically.

Just make sure the path you are proxying is the same as the servlet context, i.e. don’t proxy
http://yourhostname/some_other_name to http://localhost:8080/geoserver

Hope that helps, make sure you have the proxy working internally before you start worrying about the NAT.

Regarding hosting: I don’t know of any GeoServer / Postgresql specific hosting facilities. Personally I use hetzner.de a lot (49 Euros per month for the cheapest dedicated box, if you’re comfy with Linux). You can also try Amazon EC2 or other VPSs for a small installation, but unfortunately I have no specific advice to offer.

-Arne

1: http://geoserver.org/display/GEOSDOC/How+to+proxy+Jetty+through+Apache+on+port+80


Arne Kepp
OpenGeo - http://opengeo.org
Expert service straight from the developers

Sure, it's only a matter of concern for the user interface, for the following reason:

If proxying is all setup, and you proxy, http://yourhostname/some_other_name to http://localhost:8080/geoserver,

then your client makes a request for a page, say http://yourhostname/some_other_name/Demo.do

But what GeoServer receives is a request for http://localhost:8080/geoserver/Demo.do , since Apache has rewritten it.

GeoServer's current UI makes URL with absolute pathnames. So when it sees that the request URL was http://localhost:8080/geoserver/Demo.do , It'll return a page that has links to things like /geoserver/style.css

When the client takes this path from the returned webpage, and asks Apache for http://yourhostname/geoserver/style.css , it'll get a 404 because Apache doesn't know what to do with it. This will happen with images etc, so the UI becomes pretty useless.

However, I believe accessing WFS and WMS directly will still work, so if you don't care about configuration UI it's fine.

-Arne

Indika Tantrigoda wrote:

Hi Arne,

Thanks for the info. I think I messed my configurations in setting up the proxy.

Can u explain a little more on

/Just make sure the path you are proxying is the same as the servlet context, i.e. don't proxy
http://yourhostname/some_other_name to http://localhost:8080/geoserver/

Thanks,

Regards,
Indika

2008/12/3 Arne Kepp <ak@anonymised.com <mailto:ak@anonymised.com>>

    Indika Tantrigoda wrote:

        Hi,

        The NAT setup is not setup to work on the local network. Only
        requests coming
        from the Internet pass through the NAT. Also I dont have
        access to the DNS machine.
        So I am kinda stuck.

        Keeping the web files in /geoserver/data_dir/www seems to be a
        temporary solution,
        however in the long run I would prefer to have them in /var/www.

        I'll keep trying to find a work around for this. Maybe going
        through the server logs would shed some
        light. However I dont plan to keep the geoserver box behind a
        NAT server in the long run.

        Also can anyone point me to any services that offer geoserver
        and postgres hosting facilities.

        Thanks for all the help.

        Regards,
        Indika

    Not sure I follow on all this, but what we do at OpenGeo is
    exactly what I would do in your case. David linked to it before [1].

    The method doesn't care about NAT, just make sure you use URLs
    like "/geoserver/wfs" or "geoserver/wfs" when doing WFS queries.
    Do not tell the WFS client to use http://something:8080 , because
    if you accessed the JavaScript through :80 then it will treat
    :8080 as a different host.

    So this means you can put your HTML and JavaScript in /var/www ,
    and Apache will pretend like GeoServer lives in
    /var/www/geoserver, so http://somehostname/geoserver will work,
    and the external http://someotherhostname:8081/geoserver will also
    work automatically.

    Just make sure the path you are proxying is the same as the
    servlet context, i.e. don't proxy
    http://yourhostname/some_other_name to http://localhost:8080/geoserver

    Hope that helps, make sure you have the proxy working internally
    before you start worrying about the NAT.

    Regarding hosting: I don't know of any GeoServer / Postgresql
    specific hosting facilities. Personally I use hetzner.de
    <http://hetzner.de> a lot (49 Euros per month for the cheapest
    dedicated box, if you're comfy with Linux). You can also try
    Amazon EC2 or other VPSs for a small installation, but
    unfortunately I have no specific advice to offer.

    -Arne

    1:
    http://geoserver.org/display/GEOSDOC/How+to+proxy+Jetty+through+Apache+on+port+80

    -- Arne Kepp
    OpenGeo - http://opengeo.org
    Expert service straight from the developers

--
Arne Kepp
OpenGeo - http://opengeo.org
Expert service straight from the developers

Arne Kepp ha scritto:

Sure, it's only a matter of concern for the user interface, for the following reason:

If proxying is all setup, and you proxy, http://yourhostname/some_other_name to http://localhost:8080/geoserver,

then your client makes a request for a page, say http://yourhostname/some_other_name/Demo.do

But what GeoServer receives is a request for http://localhost:8080/geoserver/Demo.do , since Apache has rewritten it.

GeoServer's current UI makes URL with absolute pathnames. So when it sees that the request URL was http://localhost:8080/geoserver/Demo.do , It'll return a page that has links to things like /geoserver/style.css

When the client takes this path from the returned webpage, and asks Apache for http://yourhostname/geoserver/style.css , it'll get a 404 because Apache doesn't know what to do with it. This will happen with images etc, so the UI becomes pretty useless.

Actually I believe Gabriel solved this issue months ago by creating
a proxy filter that rewrites the urls in the UI on the fly.
Not sure this is documented anywhere thought...

Cheers
Andrea

--
Andrea Aime
OpenGeo - http://opengeo.org
Expert service straight from the developers.

Hi,

Thanks for all the info. Really appreciate it. I’ll follow up on this and try to get
around the issue. I’d better check up on proxying with apache first.

Regards,
Indika

2008/12/3 Andrea Aime <aaime@anonymised.com>

Arne Kepp ha scritto:

Sure, it’s only a matter of concern for the user interface, for the following reason:

If proxying is all setup, and you proxy, http://yourhostname/some_other_name to http://localhost:8080/geoserver,

then your client makes a request for a page, say http://yourhostname/some_other_name/Demo.do

But what GeoServer receives is a request for http://localhost:8080/geoserver/Demo.do , since Apache has rewritten it.

GeoServer’s current UI makes URL with absolute pathnames. So when it sees that the request URL was http://localhost:8080/geoserver/Demo.do , It’ll return a page that has links to things like /geoserver/style.css

When the client takes this path from the returned webpage, and asks Apache for http://yourhostname/geoserver/style.css , it’ll get a 404 because Apache doesn’t know what to do with it. This will happen with images etc, so the UI becomes pretty useless.

Actually I believe Gabriel solved this issue months ago by creating
a proxy filter that rewrites the urls in the UI on the fly.
Not sure this is documented anywhere thought…

Cheers
Andrea


Andrea Aime
OpenGeo - http://opengeo.org
Expert service straight from the developers.

I beleave there's no good how-to wiki page about this, but look at
http://jira.codehaus.org/browse/GEOS-1655 and
http://jira.codehaus.org/browse/GEOS-1918 for an explanation on how the
reverse proxy filter and the proxy base url parameter work.

Gabriel

On Wednesday 03 December 2008 08:36:14 Andrea Aime wrote:

Arne Kepp ha scritto:
> Sure, it's only a matter of concern for the user interface, for the
> following reason:
>
> If proxying is all setup, and you proxy,
> http://yourhostname/some_other_name to http://localhost:8080/geoserver,
>
> then your client makes a request for a page, say
> http://yourhostname/some_other_name/Demo.do
>
> But what GeoServer receives is a request for
> http://localhost:8080/geoserver/Demo.do , since Apache has rewritten it.
>
> GeoServer's current UI makes URL with absolute pathnames. So when it
> sees that the request URL was http://localhost:8080/geoserver/Demo.do ,
> It'll return a page that has links to things like /geoserver/style.css
>
> When the client takes this path from the returned webpage, and asks
> Apache for http://yourhostname/geoserver/style.css , it'll get a 404
> because Apache doesn't know what to do with it. This will happen with
> images etc, so the UI becomes pretty useless.

Actually I believe Gabriel solved this issue months ago by creating
a proxy filter that rewrites the urls in the UI on the fly.
Not sure this is documented anywhere thought...

Cheers
Andrea