git clone https://github.com/fdintino/nginx-upload-module.git git clone https://github.com/openresty/lua-nginx-module.git git clone https://github.com/simplresty/ngx_devel_kit.git 查看加载哪些模块: ~/local/nginx/sbin/nginx -V 安装luajit: make PREFIX=/home/work/local/luajit make install PREFIX=/home/work/local/luajit 设置luajit系统变量: export LUAJIT_LIB=/home/work/local/luajit/lib export LUAJIT_INC=/home/work/local/luajit/include/luajit-2.1 配置nginx: ./configure --prefix=/home/work/local/nginx_upload --with-ipv6 --with-http_ssl_module --with-http_realip_module --with-http_addition_module --with-http_dav_module --with-http_flv_module --with-http_mp4_module --with-http_gzip_static_module --with-http_perl_module --with-mail --with-mail_ssl_module --add-module=../lua-nginx-module --add-module=../nginx-upload-module --add-module=../ngx_devel_kit --with-ld-opt=-Wl,-rpath,/home/work/local/luajit/lib make -j2 make install