Nginx for Windows
tenji edited this page Mar 28, 2018
·
2 revisions
$ start nginx
$ nginx -s stop
- 首先在 nginx 安装目录中创建 ssl 文件夹用于存放证书。比如我的文件目录为:D:\Program Files\nginx-1.12.2\ssl
- 创建私钥
openssl genrsa -des3 -out nginx.key 1024
- 创建csr证书
openssl req -new -key nginx.key -out nginx.csr
- 去除密码
openssl rsa -in nginx.key.org -out nginx.key
- 生成crt证书
openssl x509 -req -days 365 -in nginx.csr -signkey nginx.key -out nginx.crt
- 修改nginx.conf文件