-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathnginx.conf
45 lines (36 loc) · 936 Bytes
/
nginx.conf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
worker_processes 4;
error_log stderr notice;
daemon off;
pid logs/nginx.pid;
events {
worker_connections 1024;
}
http {
sendfile on;
include ./mime.types;
# lua_package_path "./app/?.lua;./?.lua;/usr/local/lor/?.lua;;;;";
# 包目录
lua_package_path "./?.lua;;;;";
lua_code_cache on;
server {
# List port
listen 8123;
# Access log
access_log logs/dev-access.log;
# error log LEVEL : debug,info,notice,warn,error,crit
# Error log
error_log logs/dev-error.log notice;
# this variable is for view render(lua-resty-template)
set $template_root '';
location /static {
alias ./app/static; #app/static;
}
location / {
default_type text/html;
resolver 114.114.114.114;
content_by_lua_block {
require("lapis").serve("app")
}
}
}
}