linuxlaravelservercentoscpanel

Cpanel is not giving me option to change the root directory for one of my domains


I need to change the root directory for one of my domains,

But in my cpanel i dont find any options, just hard cores of system, but i have very basic knowledge about systems and servers.

How i can change that directory as easy as possible? I just need to change something because im gonna install laravel, and i want to change the public html to the public of laravel.

I was looking for the file that has the apache config, but it says like "the current config doesnt need to be changed or updated, bacause can be overryde", so i tought in Cpanel maybe i got an option for this.

Thanks, By the way i got an VPS, not shared. Using CENTOS 7.9.

Thanks and good night ^^


Solution

  • In cPanel, you can't change main domain directory/document root. If you want to change the document root, just change the main domain to another/random domain. Then add the domain that you want to change the root directory as addon domain

    It's not recommended overriding Apache config. It's may break your system. WHM/cPanel exists to manage domains without a system admin knowledge