salix/services/nginx/nginx.mst

30 lines
608 B
Plaintext
Raw Normal View History

2018-12-27 15:10:55 +00:00
server {
listen 80 default_server;
listen [::]:80 default_server;
server_name _;
autoindex off;
2018-12-27 15:10:55 +00:00
root /usr/share/nginx/html;
2018-12-27 15:10:55 +00:00
{{#services}}
location ~ ^/{{.}}(?:/(.*))?$ {
2018-12-31 13:02:46 +00:00
resolver 127.0.0.11;
proxy_pass http://api:{{defaultPort}}/$1$is_args$args;
2018-12-27 15:10:55 +00:00
}
{{/services}}
2019-01-15 07:12:37 +00:00
location ~ ^/mailer(?:/(.*))?$ {
resolver 127.0.0.11;
proxy_pass http://mailer:{{defaultPort}}/$1$is_args$args;
}
2018-12-27 15:10:55 +00:00
location ~ ^/static(?:/(.*))?$ {
alias /salix/dist/$1;
autoindex on;
}
location ~ ^(?:/(.*))?$ {
2018-12-31 13:02:46 +00:00
resolver 127.0.0.11;
proxy_pass http://api:{{defaultPort}}/$1$is_args$args;
}
}