How to Set Custom DocumentRoot for a Domain in DirectAdmin

By | April 18, 2019

If you need to permanently change Apache DocumentRoot for just a single domain, you should do this as Admin.

Go to

http://[domain]:2222/CMD_CUSTOM_HTTPD?domain=[domain]

In the first window, under

Only add the few lines of the VirtualHost you need to insert.
Do not add a whole ..

Add the following line:

|?DOCROOT=/custom/document/root|

Don’t forget to put pipes at the start and at the end of this line. You’re done, default DocumentRoot value will be replaced with the path you specified!

One thought on “How to Set Custom DocumentRoot for a Domain in DirectAdmin

Leave a Reply

Your email address will not be published. Required fields are marked *