• Please be aware: Kaspersky Anti-Virus has been deprecated
    With the upgrade to Plesk Obsidian 18.0.64, "Kaspersky Anti-Virus for Servers" will be automatically removed from the servers it is installed on. We recommend that you migrate to Sophos Anti-Virus for Servers.
  • The Horde webmail has been deprecated. Its complete removal is scheduled for April 2025. For details and recommended actions, see the Feature and Deprecation Plan.
  • We’re working on enhancing the Monitoring feature in Plesk, and we could really use your expertise! If you’re open to sharing your experiences with server and website monitoring or providing feedback, we’d love to have a one-hour online meeting with you.

running zope by means of mod_rewrite

T

twold

Guest
Hi everybody.
I am trying to run zope instance from plesk. I've already found out that I have to use vhost.conf, but that's everything I was able to find.
I tried to put there something like this:

Code:
  RewriteEngine on
  RewriteRule ^/(.*) [url]http://62.176.162.30:8080/VirtualHostBase/http/test.www43.com:80/plone/VirtualHostRoot/[/url]$1 [L,P]

This rule is ok, when run from normal apache server, but I am not able to figure out how to get it running from behind plesk.

Am I doing something wrong?
Or is this completely wrong approach?
Anyway, please let me know how to set it up correctly.
Thanks
 
Hi, Please search the forum, I posted some time ago the way to install and configure zope + plone to run under plesk, using separeted python :)

Tia
 
Hi Spyder, thanks for reply!
I already searched the little about the zope in the forum there was and have seen your tutorial, but that's not what I want to do.
I have single zope instance running elsewhere that manages all the plone sites (as I do not see the point of creating a zope instance for every domain I host)
IMHO, my problem is implementing mod_rewrite into Plesk. As I wrote, I can do it with bare apache, but wasn't able to get it running via plesk vhost.conf.
So, can you please tell me, if it suffices to add "RewriteEngine On" and "RewiteRule from...to" to the vhost.conf? ...from your tutorial it looks it does, but that doesn't seem to work for me.

Btw, I am not the admin of the site, where it is supposed to run. But as the admin is currently away and our company has deadlines to setup our plone sites, I am the one who has to do it :) . So maybe something else is not working, maybe mod_rewrite is not running at all. I do not know, because I really know very little of plesk (again, I am not admin) and I wasn't able to find even the main httpd.conf that plesk uses. Could you point me in the right direction?

Thanks.
 
Forgive-me for delay :)

dumb question... did you restarded apache after editing the vhosts.conf ??

Besides plesk do this time to time I prefer every modification restart apache.

The point in mantain several zopes is easy to me do maintance in separeted clients.. one zope instance non interfer with other.. client instance..

Tia.
 
Although I'm sure this quesiton has already been asked to you directly, I don't see it in the forums, so I must do my part and as if you've told psa to update the apache files. This should be a simple: /usr/local/psa/admin/bin/websrvmng -a
After that, a service apache restart (or restarting apache through the Plesk interface) should allow for the new changes to the config to be noticed by apache. This should get your vhost.conf directives working. They may not be doing what you want them to, but it should allow them to work.
 
Ok ... it´s an option, but without restart of daemon nothin is done :)


./websrvmng -a => reconfigure ....


./websrvmng -r => restart

or ./websrvmng -h | more

Tia.
 
Originally posted by Spyder
Ok ... it´s an option, but without restart of daemon nothin is done :)


./websrvmng -a => reconfigure ....

Without first reconfiguring, if no vhost.conf file was there before, apache wont know to follow any specific directives, as the httpd.include for the domain wont reference the vhost.conf file. So, if you fail to do the reconfigure, doing the restart will do nothing. And I did include a forced restart for the deamon, with two different methods to access that.
 
Hi everyone and thanks for replies!
I figured out the restart stuff already, I realized that -a option did just reconfigure the confs, not doing anything useful really :)
So, here's where I am now: I succesfully rewritten the URL, but I keep getting some permission denied message and have really no idea where could that one come from.
here's the link: My plone site

Another thing is configuration already present. There was an DocumentRoot directive in there and it pointed to our physical host. Is it of any importance when the mod_rewrite is activated?
 
verify the outpu of runzope script... and check if the user running zope

---
vi zope.conv

There are two sections you need to edit,
effective-user and servers. Where it says:
---

is the same who own the files (basicaly in my instalations the same as ftp user for domain.

about the websrvmng point..

Generaly I simple editing the

/usr/local/psa/home/vhosts/some_domain/conf/httpd.include

puting the


Include /usr/local/psa/home/vhosts/some_domain/conf/vhost.conf

statment before the </VirtualHost>

and in the vhost.conf put this..

#Hack to rewrite deliver Zope content
RewriteEngine On
RewriteLog "/usr/local/psa/home/vhosts/some_domain/statistics/logs/access_log combined rewrite_log"
RewriteLogLevel 0
RewriteRule ^/local/ - [L]
RewriteRule ^/(.*) http://some_domain:8080/VirtualHostBase/http/%{HTTP_HOST
}:80/$1 [L,P]
#hack tp 20 Mb upload file
<Directory /usr/local/psa/home/vhosts/some_domain/httpdocs>
php_admin_value upload_max_filesize "20M"
</Directory>



and restart client apache from Plesk.
 
AFAIK, effective user should be the owner of the zope-instance, not owner of the site (which is different, as I have just one global zope).

And what about the bit about servers? That should be left untouched, shouldn't it?

Well, be that as it may, I still didn't manage to get rid of the permission denied error.
Any hints left? :)
 
Btw, have you any zope sites running right now? ..Could you show me that it can work through apache, because I am starting to be quite desperate :)
 
Back
Top