码迷,mamicode.com
首页 > 其他好文 > 详细

tengine-2.1.0 + lua + base64

时间:2015-01-23 19:58:51      阅读:196      评论:0      收藏:0      [点我收藏+]

标签:

参考:http://my.oschina.net/eduosi/blog/169606

 

yum install readline
yum install readline-devel
 

wget http://www.lua.org/ftp/lua-5.3.0.tar.gz

tar xf lua-5.3.0.tar.gz

cd lua-5.3.0/        

make linux
make install
cd ..
 
wget http://luajit.org/download/LuaJIT-2.0.3.tar.gz
tar xf LuaJIT-2.0.3.tar.gz
cd LuaJIT-2.0.3/                                                                                            
make
make install
 
ln -s /usr/local/lib/libluajit-5.1.so.2 /lib64/libluajit-5.1.so.2
export LUAJIT_LIB=/usr/local/lib
export LUAJIT_INC=/usr/local/include/luajit-2.0/
 
 
cd ..
cd tengine-2.1.0
 
./configure --prefix=/usr/local/tengine-2.1.0 --dso-path=/usr/local/tengine-2.1.0/modules --with-http_realip_module --with-http_gzip_static_module --with-http_stub_status_module --with-http_concat_module --with-http_lua_module  --http-proxy-temp-path=/var/tmp/tengine-2.1.0/proxy_temp --http-fastcgi-temp-path=/var/tmp/tengine-2.1.0/fastcgi_temp --http-uwsgi-temp-path=/var/tmp/tengine-2.1.0/uwsgi_temp --http-scgi-temp-path=/var/tmp/tengine-2.1.0/cgi_temp --http-client-body-temp-path=/var/tmp/tengine-2.1.0/client_body_temp --http-log-path=/var/log/tengine-2.1.0/access.log --error-log-path=/var/log/tengine-2.1.0/error.log --with-ld-opt="-Wl,-rpath,$LUAJIT_LIB"
 
make && make install
 
useradd www
 
ln -s /usr/local/tengine-2.1.0 /usr/local/nginx
mkdir /var/tmp/tengine-2.1.0/client_body_temp -p
chown -R www /var/tmp/tengine-2.1.0

                                                                                       

 test:

 

location /lua_content {
            # MIME type determined by default_type:
            default_type ‘text/plain‘;

            content_by_lua "ngx.say(‘Hello,world!‘)";
        }

 

 

base64

 

wget http://luaforge.net/frs/download.php/2664/luasocket-2.0.2.tar.gz

tengine-2.1.0 + lua + base64

标签:

原文地址:http://www.cnblogs.com/shengshuai/p/4244851.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!