Nginx配置SSL证书

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
server {
listen 443;
server_name 127.0.0.1;

ssl on;

ssl_certificate /usr/local/cert/证书名.pem;
ssl_certificate_key /usr/local/cert/证书名.key;
ssl_session_timeout 5m;
ssl_ciphers ECDHE-RSA-AES128-GCM-SHA256:ECDHE:ECDH:AES:HIGH:!NULL:!aNULL:!MD5:!ADH:!RC4;
ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
ssl_prefer_server_ciphers on;
ssl_ciphers HIGH:!aNULL:!MD5;

location / {
proxy_pass http://127.0.0.1:8089;
}

error_page 500 502 503 504 /50x.html;
location = /50x.html {
root html;
}
}