• 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.

Question How to create all websites in same directory ?

Lionel

New Pleskian
I would like to create all websites in the same directory on centos 7 (/var/www/vhosts/thisdirectory/httpdocs)
For each website, I need one IP adress (so I can't create websites in the same subscription because all website in the same subscription have the same IP) and I need to have ssl with Lets Encrypt.

For now, I have done differents subscription and domains and put in "Apache & Nginx Settings" for each domains :
Code:
DocumentRoot "/var/www/vhosts/thisdirectory/httpdocs"
ServerName www.myfirstwebsite.com
ProxyPassMatch ^/(.*\.php(/.*)?)$ unix:/var/www/vhosts/system/thisdirectory/php-fpm.sock|fcgi://127.0.0.1/var/www/vhosts/thisdirectory/httpdocs/$1

It's works well but not when I try to put ssl with Lets Encrypt (message is that LE can't find the file it create).
I think that Plesk create the directory .well-known/acme-challenge/ in the directory created by plesk : /var/www/vhosts/myfirstwebsite.com/httpdocs

I would like that plesk always put all websites in the same directory. Which file contains the structure of the creation of directory (/www/vhosts/%domain%/) ?
 
I find the problem : when I put a virtualhost, Nginx with Plesk doesn't care about the virtual host. To make Lets Encrypt works well with Plesk when website is in a virtual host, you must NOT use Nginx... Hope Plesk will do something for this !
 
Out of curiosity: Why can't you simply create a subscription per domain? Each subscription can have its own IP address and can use SSL.
 
Each domain have its own subscription and its own IP. But I need all domains to be in the same directory (php files). Beacause I update the files every week, it's easier for me to update only one directory (and take less space on hdd).
When I put virtual host for Apache, it's works well. But with Nginx, it is not possible to redefine the root directory. Plesk should "see" that there is a virtual directory for apache and so, it should put the virtual directory (the root document) for Nginx same than the directory for apache. But for now, Plesk don't do that... I desactivate Nginx, keep my virtual host for apache and Lets encrypt can renew the SSL.
 
Back
Top