Mercurial Hosting > hghosting
comparison nginx.ssl.conf.luan @ 0:dfc36e7ed22c
init
| author | Vadim Filimonov <fffilimonov@yandex.ru> |
|---|---|
| date | Thu, 12 May 2022 13:51:59 +0400 |
| parents | |
| children |
comparison
equal
deleted
inserted
replaced
| -1:000000000000 | 0:dfc36e7ed22c |
|---|---|
| 1 local rootDir, domain = ... | |
| 2 | |
| 3 %> | |
| 4 server { | |
| 5 server_name <%=domain%>; | |
| 6 listen 80; | |
| 7 return 301 https://$http_host$request_uri; | |
| 8 } | |
| 9 | |
| 10 server { | |
| 11 server_name <%=domain%>; | |
| 12 listen 443 ssl; | |
| 13 | |
| 14 if ($host != $server_name) { | |
| 15 return 301 http://$http_host$request_uri; | |
| 16 } | |
| 17 | |
| 18 ssl_certificate <%=rootDir%>/local/ssl/<%=domain%>/fullchain.cer; | |
| 19 ssl_certificate_key <%=rootDir%>/local/ssl/<%=domain%>/<%=domain%>.key; | |
| 20 include <%=rootDir%>/nginx.default.conf; | |
| 21 include <%=rootDir%>/config/nginx.custom.*.conf; | |
| 22 include <%=rootDir%>/config/nginx.conf; | |
| 23 } | |
| 24 <% |
