annotate host/startup/nginx.conf.luan @ 1630:b735ed134662

add nginx and ssl for host
author fffilimonov
date Fri, 10 Dec 2021 17:08:17 +0000
parents
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
1630
b735ed134662 add nginx and ssl for host
fffilimonov
parents:
diff changeset
1 local rootDir, user, group = ...
b735ed134662 add nginx and ssl for host
fffilimonov
parents:
diff changeset
2
b735ed134662 add nginx and ssl for host
fffilimonov
parents:
diff changeset
3 %>
b735ed134662 add nginx and ssl for host
fffilimonov
parents:
diff changeset
4 worker_processes 4;
b735ed134662 add nginx and ssl for host
fffilimonov
parents:
diff changeset
5 user <%=user%> <%=group%>;
b735ed134662 add nginx and ssl for host
fffilimonov
parents:
diff changeset
6
b735ed134662 add nginx and ssl for host
fffilimonov
parents:
diff changeset
7 events {
b735ed134662 add nginx and ssl for host
fffilimonov
parents:
diff changeset
8 worker_connections 4096;
b735ed134662 add nginx and ssl for host
fffilimonov
parents:
diff changeset
9 }
b735ed134662 add nginx and ssl for host
fffilimonov
parents:
diff changeset
10
b735ed134662 add nginx and ssl for host
fffilimonov
parents:
diff changeset
11 http {
b735ed134662 add nginx and ssl for host
fffilimonov
parents:
diff changeset
12 include mime.types;
b735ed134662 add nginx and ssl for host
fffilimonov
parents:
diff changeset
13 default_type application/octet-stream;
b735ed134662 add nginx and ssl for host
fffilimonov
parents:
diff changeset
14 sendfile on;
b735ed134662 add nginx and ssl for host
fffilimonov
parents:
diff changeset
15 keepalive_timeout 65;
b735ed134662 add nginx and ssl for host
fffilimonov
parents:
diff changeset
16
b735ed134662 add nginx and ssl for host
fffilimonov
parents:
diff changeset
17 proxy_cache_path <%=rootDir%>/local/nginx_cache levels=1:2 keys_zone=nginx_cache:60m max_size=10g inactive=60m use_temp_path=off;
b735ed134662 add nginx and ssl for host
fffilimonov
parents:
diff changeset
18
b735ed134662 add nginx and ssl for host
fffilimonov
parents:
diff changeset
19 upstream luan {
b735ed134662 add nginx and ssl for host
fffilimonov
parents:
diff changeset
20 server 127.0.0.1:8080;
b735ed134662 add nginx and ssl for host
fffilimonov
parents:
diff changeset
21 }
b735ed134662 add nginx and ssl for host
fffilimonov
parents:
diff changeset
22
b735ed134662 add nginx and ssl for host
fffilimonov
parents:
diff changeset
23 server {
b735ed134662 add nginx and ssl for host
fffilimonov
parents:
diff changeset
24 listen 80 default_server;
b735ed134662 add nginx and ssl for host
fffilimonov
parents:
diff changeset
25 include nginx.default.conf;
b735ed134662 add nginx and ssl for host
fffilimonov
parents:
diff changeset
26 }
b735ed134662 add nginx and ssl for host
fffilimonov
parents:
diff changeset
27
b735ed134662 add nginx and ssl for host
fffilimonov
parents:
diff changeset
28 include <%=rootDir%>/sites/*/nginx.ssl.conf;
b735ed134662 add nginx and ssl for host
fffilimonov
parents:
diff changeset
29 }
b735ed134662 add nginx and ssl for host
fffilimonov
parents:
diff changeset
30 <%