# Domaine framboise.parc # hôte virtuel framboise.parc server { listen 80; listen [::]:80; server_name framboise.parc; root /var/www/html/; index index.php index.html index.htm index.nginx-debian.html; location / { try_files $uri $uri/ =404; } location ~ \.php$ { include snippets/fastcgi-php.conf; fastcgi_pass unix:/var/run/php/php7.3-fpm.sock; #~ fastcgi_pass unix:/var/run/php5-fpm.sock; } location ~ /\.ht { deny all; } } # doc.framboise.parc server { listen 80; listen [::]:80; server_name doc.framboise.parc; root /var/www/html/doc; location / { index index.php index.html index.htm index.nginx-debian.html; try_files $uri $uri/ =404; } location ~ \.php$ { include snippets/fastcgi-php.conf; fastcgi_pass unix:/var/run/php/php7.3-fpm.sock; } location ~ /(data|conf|bin|inc)/ { deny all; } location ~ /\.ht { deny all; } } # hôtes virtuels dokuwiki server { listen 80; listen [::]:80; server_name ~^(?Pdoc|perso|magie)\.framboise\.parc$; #server_name doc.framboise.parc; #root /var/www/html/doc; root /var/www/html/$sub; location / { index index.php index.html index.htm index.nginx-debian.html; try_files $uri $uri/ =404; } location ~ \.php$ { include snippets/fastcgi-php.conf; #~ fastcgi_pass unix:/var/run/php/php7.3-fpm.sock; fastcgi_pass unix:/var/run/php5-fpm.sock; } location ~ /(data|conf|bin|inc)/ { deny all; } location ~ /\.ht { deny all; } } # hôte virtuel test.framboise.parc server { listen 80; listen [::]:80; server_name test.framboise.parc; root /var/www/html/test; location / { index index.php index.html index.htm index.nginx-debian.html; try_files $uri $uri/ =404; } location ~ \.php$ { include snippets/fastcgi-php.conf; fastcgi_pass unix:/var/run/php/php7.3-fpm.sock; #~ fastcgi_pass unix:/var/run/php5-fpm.sock; } location ~ /(data|conf|bin|inc)/ { deny all; } location ~ /\.ht { deny all; } } #~ # hôte virtuel gestion.framboise.parc server { listen 80; listen [::]:80; server_name gestion.framboise.parc; root /var/www/html/gestion/htdocs; location / { index index.php index.html index.htm index.nginx-debian.html; try_files $uri $uri/ =404; } location ~ \.php$ { include snippets/fastcgi-php.conf; fastcgi_pass unix:/var/run/php/php7.3-fpm.sock; #~ fastcgi_pass unix:/var/run/php5-fpm.sock; } location ~ /(data|conf|bin|inc)/ { deny all; } location ~ /\.ht { deny all; } } #~ # hôte virtuel perso.framboise.parc server { listen 80; listen [::]:80; server_name perso.framboise.parc; root /var/www/html/perso; location / { index index.php index.html index.htm index.nginx-debian.html; try_files $uri $uri/ =404; } location ~ \.php$ { include snippets/fastcgi-php.conf; fastcgi_pass unix:/var/run/php/php7.3-fpm.sock; #~ fastcgi_pass unix:/var/run/php5-fpm.sock; } location ~ /(data|conf|bin|inc)/ { deny all; } location ~ /\.ht { deny all; } } # hôte virtuel *.framboise.parc server { listen 80; listen [::]:80; # On récupère le sous-domaine dans la variable "sub". server_name ~^(?P.+)\.framboise.parc$; root /var/www/html/$sub; index index.php index.html index.htm index.nginx-debian.html; location / { try_files $uri $uri/ =404; } location ~ \.php$ { include snippets/fastcgi-php.conf; fastcgi_pass unix:/var/run/php/php7.3-fpm.sock; #~ fastcgi_pass unix:/var/run/php5-fpm.sock; } location ~ /\.ht { deny all; } }