yhurl.conf
470 Bytes
## generate short url and redirect short url
server {
listen 80 ;
server_name yhurl.com ;
access_log /Data/logs/nginx/yhurl.com_access.log fenxi;
error_log /Data/logs/nginx/yhurl.com_error.log;
#generate short url
location = /gs {
default_type application/json;
content_by_lua_file conf/lua/short_url_generate.lua;
}
#redirect
location / {
content_by_lua_file conf/lua/short_url_redirect.lua;
}
}