Files
2026-08-01 16:11:49 +03:00

26 lines
559 B
Plaintext

---
source: loco-gen/tests/templates/deployment.rs
expression: "fs::read_to_string(tree_fs.root.join(\"nginx\").join(\"default.conf\")).expect(\"nginx config missing\")"
---
server {
listen 80;
server_name ~^(?<subdomain>\w*)\.localhost$;
location / {
if ($http_x_subdomain = "") {
set $http_x_subdomain $subdomain;
}
proxy_set_header X-Subdomain $http_x_subdomain;
proxy_pass http://localhost:8080/;
}
}
server {
listen 80;
server_name localhost;
location / {
proxy_pass http://localhost:8080/;
}
}