openssl 1.1.1 版本
node v10
npm i -D pm2
npm i -g pm2
pm2 start npm -- run dev
pm2 list
pm2 show id
pm2 monit
pm2 logs
pm2 reload all
pm2 stop <app_name|id|'all'|json_conf>
pm2 restart <app_name|id|'all'|json_conf>
pm2 delete <app_name|id|'all'|json_conf>
开发环境
./app/env/dev/gencert.sh
需要配置 rootCA.conf
和 server.conf
生产根证书, 前面证书
openssl version -a
openssl genrsa -des3 -out rootCA.key 2048
openssl req -x509 -new -config rootCA.conf -key rootCA.key -sha256 -days 3650 -out rootCA.pem
Settings -> Advanced -> Manage certificates
选择 System
选择 Certificates
选择证书文件, 查看 detail -> Trust -> When using this certificate -> Always Trust
certificate signing request
openssl genrsa -out server.key 2048
openssl req -new -config server.conf -out server.csr
创建一个v3.ext文件,以创建一个X509 v3证书。注意我们指定了subjectAltName选项
openssl x509 -req -in server.csr -CA rootCA.pem -CAkey rootCA.key -CAcreateserial -out server.crt -days 3650 -sha256 -extfile v3.ext