[opencms-dev] OpenCMS9 and Tomcat7 - Configuration no ROOT

Arash Kaffamanesh ak at cloudssky.com
Mon Jul 25 21:43:20 CEST 2016


Hi,

I'd a similar issue, and I'd to enable SSL for the workplace.

And you might find some information here:

https://docs.google.com/document/d/1PUNVQXecxABjf5WNh1xb1CWY-FIBZgOTPO1neIi6EgI/edit#heading=h.r4ba2ls3mq1o

Did you set sessionCookiePath="/" in the context tag of context.xml file:

$  vi /var/lib/tomcat7/conf/context.xml

<!-- Context -->
<Context sessionCookiePath="/">

By the way this OpenCms 9.5.3 Docker image is using OpenJDK 8, Tomcat 8,
Apache 2 and MariaDB 10 installation:

https://hub.docker.com/r/cloudssky/opencms-stack-local/


HTH,

Kind Regards,
Arash







On Mon, Jul 25, 2016 at 12:25 PM, Andrea Lasi - ConsulMedia srl <
alasi at consulmedia.it> wrote:

> Hi,
> I have this server configuration:
>  - Tomcat7
>  - Apache 2.4
>  - OpenCMS 9.5.4
>
> I need to remove {CONTEXT_NAME}/opencms from URL.
>
> With Tomcat6 Apache OpenCMS 9.5.x I use this configuration
>
> WEB-INF/config/opencms-importexport.xml
> *<rendersettings>*
> *    <rfs-prefix>/export</rfs-prefix>*
> *    <vfs-prefix></vfs-prefix>*
> *    ...*
> *</rendersettings>*
>
> WEB-INF/config/opencms-system.xml
> *<sites>*
> *    <workplace-server>http://{DOMAIN}</workplace-server>*
> *    <default-uri>/sites/default/</default-uri>*
> *    <site server="**http://{DOMAIN}**" uri="/sites/default/"/>*
> *    ...*
> *</sites>*
>
> VirtualHost
> *<VirtualHost 158.58.173.69:80 <http://158.58.173.69:80>>*
> *    ServerAdmin info@{MY-DOMAIN-NAME}.com*
> *    ServerName www.{MY-DOMAIN-NAME}.com*
> *    ServerAlias {MY-DOMAIN-NAME}.com*
> *    ErrorLog ${APACHE_LOG_DIR}/{MY-DOMAIN-NAME}.com-error_log*
> *    CustomLog ${APACHE_LOG_DIR}/{MY-DOMAIN-NAME}AWS.com-access_log
> combined*
> *    DirectoryIndex index.html*
>
> *    # If the requested URI is located in the resources folder, do not
> forward the request*
> *    SetEnvIfNoCase Request_URI ^/{MY-CONTEXT-NAME}/resources/.*$ no-jk*
>
> *    # If the requested URI is static content do not forward the request*
> *    SetEnvIfNoCase Request_URI ^/export/.*$ no-jk*
>
> *    RewriteEngine on*
> *    # If the requested URI is NOT located in the resources folder.*
> *    # Prepend an /isgas/opencms to everything that does not already
> starts with it*
> *    # and force the result to be handled by the next URI-handler ([PT])
> (JkMount in this case)*
> *    RewriteCond %{REQUEST_URI} !^/{MY-CONTEXT-NAME}/resources/.*$*
> *    RewriteCond %{REQUEST_URI} !^/export/.*$*
> *    RewriteRule !^/{MY-CONTEXT-NAME}/opencms/(.*)$
> /{MY-CONTEXT-NAME}/opencms%{REQUEST_URI} [PT]*
>
> *    # These are the settings for static export. If the requested resource
> is not already*
> *    # statically exported create a new request to the opencms404 handler.
> This has to be*
> *    # a new request, because the current would net get through mod_jk
> because of the "no-jk" var.*
> *    RewriteCond %{REQUEST_URI} ^/export/.*$*
> *    RewriteCond "%{DOCUMENT_ROOT}%{REQUEST_FILENAME}" !-f*
> *    RewriteCond "%{DOCUMENT_ROOT}%{REQUEST_FILENAME}/index_export.html"
> !-f*
> *    RewriteRule .*
> /{MY-CONTEXT-NAME}/opencms/handle404?exporturi=%{REQUEST_URI}&%{QUERY_STRING}
> [P]*
>
> *    # If the request starts with /{MY-CONTEXT-NAME}/resources, delete the
> /{MY-CONTEXT-NAME} prefix*
> *    RewriteCond %{REQUEST_URI} ^/{MY-CONTEXT-NAME}/resources/.*$*
> *    RewriteRule ^/{MY-CONTEXT-NAME}/(.*)$ /$1*
>
> *     DocumentRoot /MY/DOCUMENT/ROOT*
> *    JkMount /* ajpconnector*
> *</VirtualHost>*
>
> If I use this configuration in Tomcat7 I see the site in online view but
> if I do the login in http://www.{MY-DOMAIN-NAME}.com/system/login I have
> no error in logs but I'm not redirect in Workplace (or in the home
> editable) but I have redirect always in online view. Is it correctable?
> Can I use OpenCMS9.5.x with Tomcat7 (or 8) anche Apache configuring all as
> I did with Tomcat6?
>
> So I follow this documentation but I have the problem that my OpenCMS
> can't be the ROOT (I have some OpenCMS instances and I can't put a Tomcat
> installation for each)
>
> http://documentation.opencms.org/opencms-documentation/server-installation/apache-webserver-configuration/
>
> Thanks
> Andrea
>
> _______________________________________________
> This mail is sent to you from the opencms-dev mailing list
> To change your list options, or to unsubscribe from the list, please visit
> http://lists.opencms.org/cgi-bin/mailman/listinfo/opencms-dev
>
>
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://webmail.opencms.org/pipermail/opencms-dev/attachments/20160725/d1559c2e/attachment.htm>


More information about the opencms-dev mailing list