Am 19.04.2011 00:08, schrieb Sergiu Dumitriu:
> On 04/18/2011 03:52 PM, li...@yhmail.de wrote:
>> Hey,
>>
>> thanks it works now. At least I do not get any errors at the moment.
>> Could you explain to me what the difference is? (HTTP vs. ajp) When proxying?
> ajp is a direct connection between httpd and tomcat, which basically
> lets Tomcat take care of a request on behalf of httpd. The request
> details are kept in place, including the hostname, the port, whether the
> connection is secure (SSL/https) or not...
>
> HTTP proxying means that httpd clones the initial client request as a
> new http request to the Tomcat server. Thus, unless specifically
> configured to try and pass some details from the initial request, Tomcat
> will just see this as an ordinary request done to "localhost" on port 8080.
>
> ProxyPass, ProxyPassReverse and ProxyPreserveHost try to keep the same
> hostname (www.my-domain.de instead of localhost), but don't keep the
> fact that HTTPS was used.

Thanks for the backgrounder !

> The problem with the blog is that unlike most parts of the wiki,
> absolute URLs are used when creating a new category. This means that a
> full URL, trying to match the requested URL, is computed. Now, since
> Tomcat/XWiki doesn't really know the original URL, the generated URL
> will be most likely wrong, pointing to the wrong host and port.

Couldn't that / shouldn't that be changed so that its possible to 
reliably operate
XWiki with all of its features behind a httpd ?
I think a lot of people are doing that (including me). Never tried 
blogging though ....
Are other parts of XWiki also affected by this 'wrong' computation of 
the url ?

kind regards

Andreas



>> @Everybody: Thank you for your help.
>>
>> Cheers,
>> Chris
>>
>>
>> Quoting "Kevin P. Foote"<kpfo...@iup.edu>:
>>
>>> Stephanie -
>>>
>>> I use mod_jk for other reasons.. but mod_proxy_ajp is similar.. there is no
>>> reason why this should not work ..
>>>
>>> Make some changes though..
>>>
>>> In your httpd conf where you have your virtual host defined
>>>
>>> change ServerName to the full address
>>>
>>> ServerName https://www.my-domain.de
>>>
>>> Dont proxy to tomcat via http... use tomcat in ajp mode ..
>>> disable port :8080 and server xwiki over :8009 only to local host via
>>> your<tomcat location>/conf/server.xml file. (usually all you need to do
>>> is comment the 8080 stuff and uncomment the 8009.
>>>
>>> your proxy string will look something like this then..
>>>
>>> ProxyPass /xwikiv2 ajp://localhost:8009/<xwiki instance>
>>>
>>>
>>> ------
>>> thanks
>>>     kevin.foote
>>>
>>> On Mon, 18 Apr 2011, li...@yhmail.de wrote:
>>>
>>> ->   Hello again,
>>> ->
>>> ->   we are running a tomcat-server "behind" an apache-server. In order to
>>> ->   redirect the request we use the following configuration:
>>> ->
>>> ->   <VirtualHost *:80>
>>> ->            ServerName      www.my-domain.de
>>> ->            ServerAlias     my-domain.de
>>> ->            Redirect permanent / https://www.my-domain.de/
>>> ->   </VirtualHost>
>>> ->
>>> ->   <VirtualHost *:443>
>>> ->            ServerName      www.my-domain.de
>>> ->
>>> ->            SSLEngine       On
>>> ->            SSLProxyEngine  On
>>> ->
>>> ->        SSLCertificateFile /etc/apache2/ssl/my-domain.crt
>>> ->        SSLCertificateKeyFile /etc/apache2/ssl/my-domain.key
>>> ->
>>> ->            <Proxy *>
>>> ->                    Order   allow,deny
>>> ->                    Allow   from all
>>> ->            </Proxy>
>>> ->
>>> ->
>>> ->            Redirect /              /xwikiv2/
>>> ->
>>> ->            ProxyPass /xwikiv2      http://localhost:8080/xwikiv2
>>> ->            ProxyPassReverse /xwikiv2 http://localhost:8080/xwikiv2
>>> ->            ProxyPreserveHost       On
>>> ->   </VirtualHost>
>>> ->
>>> ->   So all communication should be encrypted and the user should
>>> ->   immediately be redirected to the wiki.
>>> ->
>>> ->   With these settings we encounter a strange behaviour. For example the
>>> ->   Blog refuses to create a new category (see: [xwiki-users] Server not
>>> ->   responding when creating a new Blog-Category). If I point my browser
>>> ->   directly to my-domain.de:8080 I can create categories.
>>> ->
>>> ->   Is the config file correct? Is there a better way?
>>> ->
>>> ->   Cheers,
>>> ->   Stephanie
>

_______________________________________________
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users

Reply via email to