jide / clamp

Command Line Apache MySQL PHP
http://jide.github.io/clamp
GNU General Public License v2.0
79 stars 9 forks source link

Multiple vhosts with Clamp #14

Open aldorr opened 8 years ago

aldorr commented 8 years ago

Does anyone have an idea of how to set up the config file to be able to use virtual hosts in clamp? I.e.: mysite.local = the regular frontend... and backend.mysite.local = the backend/cms on same server, just based in a different folder.

The Live server that I have copied the site from uses the alias module in Apache to make two different aliases: One for the frontend and one for the backend.

Thought it might work if I do something like:

    "host": {
        "options": {
            "127.0.0.1": "{{$.address}}", // address is "mysite.local" in this example
            "127.0.0.1/backend": "backend.mysite.local"
        }
    },

But obviously that is foolhardy. How might I go about this? Thanks!