信息发布→ 登录 注册 退出

nginx配置https的详细流程

发布时间:2021-01-21

点击量:

详细配置流程如下:

(学习视频分享:编程视频)

1、下载SSL证书

2、两个证书放在cert目录上然后放到nginx 与nginx.conf同目录下

3、去nginx解压目录下执行

./configure --with-http_ssl_module

如果报错 ./configure: error: SSL modules require the OpenSSL library.则执行

yum -y install openssl openssl-devel
./configure
./configure --with-http_ssl_module

4、执行 make(切记不能 make install 会覆盖安装目录)

5、将原来 nginx 备份

cp /usr/local/nginx/sbin/nginx /usr/local/nginx/sbin/nginx.bak

6、将新的 nginx 覆盖旧安装目录

cp objs/nginx /usr/local/nginx/sbin/nginx

如果报错,执行

cp -rfp objs/nginx /usr/local/nginx/sbin/nginx

完成。

相关推荐:nginx教程

标签:# nginx  # 报错  # 安装目录  # 放在  # 目录下  # configure  # http_ssl_module  # error  # library  # yum  # OpenSSL  
在线客服
服务热线

服务热线

4008888355

微信咨询
二维码
返回顶部
×二维码

截屏,微信识别二维码

打开微信

微信号已复制,请打开微信添加咨询详情!