2 Replies Latest reply: May 29, 2013 10:24 AM by 1011444 RSS

    SSI from third party server

    1011444
      Hi All!
      I have two iPlanet 7 web servers running on Solaris 9
      One server is outside firewall and second is behind firewall.
      We need to be able to pull Server Side Includes from some other server (www.somehost.com).
      I tried to enable SSI on virtual server and entered www.somehost.com in the URI field, but that doesn't work.
      Could you please provide me with step by step instructions of how to achieve this.
        • 1. Re: SSI from third party server
          Pascal Kreyer-Oracle
          SSI is just for local file systems. But if you want remote files, you can still use the exec directive with wget command.
          • 2. Re: SSI from third party server
            1011444
            Thanks Pascal!

            I will try wget approach.

            Also I have instructions of how to do this on Apache (see below),
            so there should be a way to do the same on iPlanet.

            To allow SSI to access files held on remote servers, a reverse proxy setup is needed.
            The following should be added to the server’s httpd.conf file:

            ProxyPass /templates http://www.somehost.com/templates
            ProxyPassReverse /templates http://www.somehost.com/templates

            If the root-relative path /templates conflicts with an existing directory,
            it may be changed to any other name desired as long as the beginning
            of the include paths are changed to match.

            To prevent server encoding from returning compressed data, the following
            should also be added to the httpd.conf file:

            +<Location /templates>+
            RequestHeader unset Accept-Encoding
            +</Location>+

            The path within the Location node should match the first path in the ProxyPass settings.

            Finally, the site directory needs to be configured to allow includes, and also to allow
            includes with .html extensions. The following can be added to the site’s Directory node
            in httpd.conf, or an .htaccess file held on the server:

            Options Includes+
            AddType text/html .html
            AddOutputFilter INCLUDES .html

            Now you can use HTML virtual includes as if the page were hosted on the
            same server as the include:

            +<!--#include virtual="/templates/template.html" -->+

            If Apache server is behind a firewall, the requests for
            those directories need to forward to an outbound proxy.
            The following addition to httpd.conf will allow for this:

            +# Be careful with lines below. You should probably add some security around this with the <Proxy *> directive+
            +# This is an example and this should be configured based on your environment+
            ProxyRequests On
            ProxyRemote http://www.somehost.com/ <**your proxy host**>:3128