IT博客汇
  • 首页
  • 精华
  • 技术
  • 设计
  • 资讯
  • 扯淡
  • 权利声明
  • 登录 注册

    重新编译OpenResty支持http2

    the5fire发表于 2017-01-11 22:24:57
    love 0

    把主机迁到ConoHa上之后用上了OpenResty,想着以后直接前端加+Lua+数据库也能搞一个项目出来。今天在用HTTP2 and SPDY插件看是否为http2访问时突然不是。于是查了下发现是openssl版本太低了,于是升级了下。列出命令:

    cd /opt/
    wget https://www.openssl.org/source/openssl-1.0.2-latest.tar.gz
    tar -xvf openssl-1.0.2-laest.tar.gz
    
    # 重新编译openresty
    cd /opt/openresty/
    ./configure --prefix=/opt/openresty --with-luajit             --without-http_redis2_module             --with-http_iconv_module --with-http_v2_module --with-openssl=/opt/openssl-1.0.2j
    # 完成之后直接gmake && gmake install(或者make && make install)
    # 运行中的nginx不需要关掉,安装完之后先stop然后再重启即可。
    
    nginx stop
    
    nginx -c conf
    


沪ICP备19023445号-2号
友情链接