CentOS7 OpenResty安装LuaRocks帮助我们管理组件

1、下载

wget http://luarocks.org/releases/luarocks-2.0.13.tar.gz

2、解压并进入目录

tar -zxvf luarocks-2.0.13.tar.gz
cd luarocks-2.0.13

3、配置、编译、安装(默认安装的目录基本上差不多)

./configure --prefix=/usr/local/openresty/luajit --with-lua=/usr/local/openresty/luajit/  --lua-suffix=jit  --with-lua-include=/usr/local/openresty/luajit/include/luajit-2.1
make
make install

4、将其添加到环境变量中去

echo 'export PATH=$PATH:/usr/local/openresty/luajit/bin' >> /etc/profile
source /etc/profile

5、使用luarocks添加模块

luarocks install luafilesystem

 

posted @ 2020-06-30 07:36  HumorChen99  阅读(1)  评论(0编辑  收藏  举报  来源