- Plesk for Linux
- Apache 2.4 is installed on the server.
It is not possible to create a subdomain using API query, the following error appears in Plesk:
CONFIG_TEXT: Template processing failed: file = /usr/local/psa/admin/conf/templates/default/domainVhost.php, error = Template_Exception: Empty content was provided for config file /var/www/vhosts/system/one.example.com/conf/httpd.conf file: /usr/local/psa/admin/plib/Template/Writer/Webserver/Abstract.php line: 47 code: 0.
This is Plesk bug with ID #PPPM-3924 which is planned to be fixed in future Plesk updates.
As a workaround, execute the API query from a different domain on the server or from a different server.
For Centos 7 Plesk 17.0, the following workaround is available:
1. Login to the server over SSH
2. Make a backup of the existing file
# mv /usr/local/psa/admin/plib/api-rpc/Agent.php /root/
2. Unpack the attached file to the
directory on the server.