This commit is contained in:
Dominic Grimm 2023-05-21 18:58:10 +02:00
commit e82f35da2a
No known key found for this signature in database
GPG key ID: B6FFE500AAD54A3A
78 changed files with 10821 additions and 0 deletions

View file

@ -0,0 +1,28 @@
map $host $subdomain {
~^(?P<sub>.+)\.{{ domain_segments|join("\\.") }}$ $sub;
}
server {
listen 80;
server_name *.{{ domain_segments|join(".") }};
root /var/www/repos/$subdomain;
location = / {
autoindex on;
}
location / {
try_files $uri $uri/ /index.html;
index index.html index.htm;
if (!-e $request_filename) {
return 404;
}
}
location ~ /\.git {
deny all;
return 404;
}
}