nginx https protocol requires SSL support in 没有启用SSL模块

Nginx 2020-02-05 阅读 1098 评论 0

在 linux 下,nginx 配置 ssl,或者反向代理 proxy_pass 带有 https 的域名,报错了,https协议需要 ssl 支持,无法启动 nginx。

nginx: [emerg] https protocol requires SSL support in /opt/nginx-1.17.8/conf/server.conf:9

解决方案是重新编译一下 nginx,加上--with-http_ssl_module,enable 启用 ngx_http_ssl_module

$ ./configure --prefix=/opt/nginx-1.17.8 --with-http_ssl_module
$ make
$ sudo make install


最后更新 2020-02-05