Hi,
I would like to do something like this:
I have got my website at this directory
/home/www-data/my-domain.com
i have got my vhost config at
/home/www-data/my-domain.com/nginx.config
I have got at /etc/nginx/nginx.conf something like this
include /home/www-data/*/nginx.conf;
It would be great if i could use variable which catch directory name (which is vhost, server name, and root path) where my vhost nginx.config exist, then i shouldn't write config for every websites which is at /home/www-data/ direcotry, i could use the same nginx.config
Is it possible with nginx to catch this directory? Or any other way?
I would like to have in nginx something like __DIR__, and end(explode("/",__DIR__) in PHP for every included vhost config files
Edited 1 time(s). Last edit at 02/23/2013 04:40PM by puregreen.