专注于 JetBrains IDEA 全家桶,永久激活,教程
持续更新 PyCharm,IDEA,WebStorm,PhpStorm,DataGrip,RubyMine,CLion,AppCode 永久激活教程

CentOS安装OpenResty

参考文档:openresty.org/cn/installa…

OpenResty的安装过程比较简单,官方文档也已经讲得很详细了,这里主要是做一下安装记录

1、安装

# 下载
wget https://openresty.org/download/openresty-1.13.6.2.tar.gz
# 安装依赖库
yum install pcre-devel openssl-devel gcc curl
# 解压
tar -zxvf openresty-1.13.6.2.tar.gz
cd openresty-1.13.6.2/
# 配置(检测环境、生成Makefile、为编译做准备)
./configure
# 编译
make
# 安装
make install

主要注意两点:

  • 安装前需要准备依赖库
  • ./configure

    默认 –prefix=/usr/local/openresty,程序会被安装到/usr/local/openresty目录

    可以自己指定各种选项,比如

    ./configure --prefix=/opt/openresty \
                --with-luajit \
                --without-http_redis2_module \
                --with-http_iconv_module \
                --with-http_postgres_module

使用 `./configure --help` 查看更多的选项

./configure运行出错可以到`build/nginx-1.13.6.2/objs/autoconf.err` 查看

2、启动

配置环境变量
shell> vim /etc/profile

添加一行

export PATH=/usr/local/openresty/bin:/usr/local/openresty/nginx/sbin:$PATH

shell> source /etc/profile

启动
shell> nginx -c /usr/local/openresty/nginx/conf/nginx.conf

重新加载配置
shell> nginx -s reload

3、测试

115_1.png

文章永久链接:https://tech.souyunku.com/40343

未经允许不得转载:搜云库技术团队 » CentOS安装OpenResty

JetBrains 全家桶,激活、破解、教程

提供 JetBrains 全家桶激活码、注册码、破解补丁下载及详细激活教程,支持 IntelliJ IDEA、PyCharm、WebStorm 等工具的永久激活。无论是破解教程,还是最新激活码,均可免费获得,帮助开发者解决常见激活问题,确保轻松破解并快速使用 JetBrains 软件。获取免费的破解补丁和激活码,快速解决激活难题,全面覆盖 2024/2025 版本!

联系我们联系我们