Source for serving and static templating/compiling of https://joshstock.in.
{#} | Time | Hash | Subject | Author | # | (+) | (-) | GPG? |
---|---|---|---|---|---|---|---|---|
38 | 02 Jan 2020 16:42 | 07297ad | Streamline nginx configuration updates | Josh Stockin | 1 | 18 | 0 | N |
1 | server { |
2 | listen 443 ssl http2; |
3 | listen [::]:443 ssl http2; |
4 | server_name git.joshstock.in; |
5 | rewrite ^/(.*)/$ /$1 permanent; # truncate forward slash |
6 | root /var/www/html; |
7 | error_page 404 /error-404.html; |
8 | rewrite_log on; |
9 | location = / { |
10 | proxy_pass http://localhost:8080/; |
11 | } |
12 | location = /favicon.ico { # the only static file we want on this domain |
13 | try_files /favicon.ico =404; |
14 | } |
15 | location / { # restrict all other endpoints |
16 | internal; |
17 | } |
18 | } |
19 |