• Introducing WebPros Cloud - a fully managed infrastructure platform purpose-built to simplify the deployment of WebPros products !  WebPros Cloud enables you to easily deliver WebPros solutions — without the complexity of managing the infrastructure.
    Join the pilot program today!
  • Support for BIND DNS has been removed from Plesk for Windows due to security and maintenance risks.
    If a Plesk for Windows server is still using BIND, the upgrade to Plesk Obsidian 18.0.70 will be unavailable until the administrator switches the DNS server to Microsoft DNS.

Directory under /httpdocs

L

lpittman

Guest
Howdy!

I'd like to create a folder below /httpdocs for files like database includes (which hold passwords) so it is not accessible by the public, but still accessible by php. I know this is possible, but can't remember how I do it (something with the vhost.conf?) ... any guidance would be appreciated!

Thanks,
Luke
 
Just to be on topic, how can I allow the domain user to create a folder one level below httpdocs? It seems to have permissions problem.

By default if you created domain.com in Plesk, the user will not have permission to write into /var/www/vhosts/domain.com unless I think if you explicitly use root to chown the dir to the user, it should work. But then again, what should be the correct way of doing such things. I am pretty confuse by what Plesk can help administrators. The documentation are only useful for the admin control panel.
 
A client can't just do this. Login as root, create the directory and use chown to set the client as the owner (and you'll probably want to add this dir to the open_basedir path if PHP is in the mix).
 
Hmm, what effect will there be if i chown the vhosts/domain.com to the domain user? Will it be too insecure?

As for the open_basedir, where can I put the php_admin_value if I wish to apply to the whole server? instead of just in a vhost.conf? I just read that you can put in as a skel. But how about just one file which will affect all sites?
 
Setting a global open_basedir path won't work because the domain specific open_basedir entries (in httpd.include or optional ones in a vhost.conf) will override the global open_basedir setting.
 
Back
Top