• Debian 11 is approaching its end-of-life (vendor EOL date - August 31, 2026). Plesk Obsidian 18.0.80 will be the last release to support it.
    If you are running Plesk Obsidian on Debian 11, we recommend you upgrade those servers to Debian 12 using our dist-upgrade tool.
  • We plan to deprecate and remove the support for XML RPC protocol versions earlier than 1.6.9.1 in Plesk Obsidian 18.0.82. We strongly recommend that you update all existing integrations using earlier versions of the XML RPC protocol to comply with the version 1.6.9.1 specification.

open_basedir for subdomains?

T

tincup

Guest
Hi. I don't know if this is off-topic in here but my web server is Plesk controlled.

I need to extend the PHP open_basedir of one of my subdomains by "/usr/share/php". So I create a file "vhost.conf" at

/var/www/vhosts/domainname.com/subdomains/subdomainname/httpdocs

with the contents

<Directory /var/www/vhosts/domainname.com/subdomains/subdomainname/httpdocs>
php_admin_value open_basedir "/var/www/vhosts/domainname.com/subdomains/subdomainname/httpdocs:/tmp:/usr/share/php"
</Directory>

This did not work. Does anyone know why?
 
Ok, got it working. This is what I did...

contained the php_admin_value open_basedir directive in:

<Directory foo/bar/httpdocs>
<IfModule sapi_apache2.c>
php_admin_flag engine on
php_admin_value open_basedir "blabla"
</IfModule>
<IfModule mod_php5.c>
php_admin_flag engine on
php_admin_value open_basedir "blabla"
</IfModule>
</Directory>

Hope it helps. I'm sure there's some redundancy there that can be cut out.
 
I have copied your code exactly, placing it in a vhost.conf file in the httpdocs folder of the subdomain as described in the first post and nothing happens!

I have restarted the httpd service and ran the following command as suggested in another thread:
/usr/local/psa/admin/sbin/websrvmng -a -v

But still nothing!

Can anyone help!
 
Thanks for your reply. Should have posted back to let everyone know I sorted it in the end after a bit of trial and error and a late night!
 
Back
Top