Trials and Tribulations With ISPConfig

So as many people know I host quite a few websites at my home on a series of small VMs. These VMs all run on the KVM hypervisor which in turn are managed by Proxmox, a VM host management OS.

All of that aside, managing 4 or 5 individual VMs each with multiple sites and multiple custom web server configs has become a nightmare, not to mention the fact that each site has it's own reverse proxy config too, more on that another day however.

Enter ISPConfig and it's wonderful web front end GUI and glorious auto configuration of server blocks and settings... that is until you need to run an advanced PHP framwork like Symfony or Laravel.

The problem stems from the fact that ISPConfig assumes all web content should live in /var/www/ which is fine if you are working with standard web conventions but not if you use a separate project folder as is the case for PHP frameworks. The various framework technologies store the project config files and such in the top level web directory and assume you will point your document root at the public directory looking something like this: root /var/www/ which of course you can manually change with ISPConfig but your change will be overwritten as soon as you use the control panel again.

This presents a somewhat unique issue that can only be overcome with NGINX directive overides or Apache overides.

In short, this snippet for NGINX will save you a lot of hassle, for Apache simply set a new document root in ISPConfig and that one will win out:

location / { try_files /public/$uri /public/$uri/ /public/index.php?$query_string; }

Trials and Tribulations With ISPConfig
Share this