server_name it-blog-cn.com;ssl_certificate /usr/local/nginx/conf/cert/it-blog-cn.com.pem; ssl_certificate_key /usr/local/nginx/conf/cert/it-blog-cn.com.key;ssl_session_cache shared:SSL:1m; ssl_session_timeout 5m;ssl_ciphers HIGH:!aNULL:!MD5; ssl_prefer_server_ciphers on;location /...
server_name admin.cjxqtalents.cn; ssl_certificate /usr/local/nginx/cert/scs1728461315872_admin.cjxqtalents.cn_server.crt; ssl_certificate_key /usr/local/nginx/cert/scs1728461315872_admin.cjxqtalents.cn_server.key; ssl_session_cache shared:SSL:1m; ssl_session_timeout 10m; ssl_ciphers HIGH:!a...
ssl_protocols TLSv1 TLSv1.1 TLSv1.2; #安全链接可选的加密协议 ssl_prefer_server_ciphers on; #使用服务器端的首选算法 location / { root /home/ruoyi-ui/dist; try_files $uri $uri/ /index.html; index index.html index.htm; } location /prod-api/ { proxy_set_header Host $http_host; pro...
如下出现SSL-Session表示HTTPS服务正常运行,服务器配置的SSL证书是可用的。如果提示connect:errno=111表示没有服务,建议检查Nginx是否启动。 [root@iZuf65h6i43ltlzhqolumyZconf]# echo | openssl s_client -connect 127.0.0.1:443 -servername it-blog.cn 2...
1. 准备SSL证书我这里使用的是域名服务商签发的SSL证书,如果你没有合法可信任的SSL证书,可以搜索签发私有证书方法。 代码语言:javascript 复制 file ssl/domain.*domain.crt:PEMcertificate domain.key:PEMRSAprivatekey 2. 配置Nginx 代码语言:javascript
_add_x_forwarded_for;proxy_set_headerX-Forwarded-Proto$scheme;proxy_set_headerX-Forwarded-Port$server_port;}error_page500502503504/50x.html;location=/50x.html{root html;}}server{listen443ssl;server_name 你的域名;root html;index index.html index.htm;ssl_certificate../cert/下载的证书.pem;ssl_...
listen [::]:443 ssl http2 default_server; server_name kafeimao.com; ssl on; ssl_certificate "/etc/letsencrypt/live/kafeimao.com/fullchain.pem"; ssl_certificate_key "/etc/letsencrypt/live/kafeimao.com/privkey.pem"; # ssl_session_cache shared:SSL:1m; ...
ssl_prefer_server_ciphers on; location / { root /home/django/project_test/boke_db/dist; try_files $uri $uri/ /index.html; index index.html index.htm; } location /api/ { proxy_set_header Host $host;#保留代理之前的host proxy_set_header X-Real-IP $remote_addr;#保留代理之前的真实客户...
在servers目录创建服务器testweb.95105813.cn的配置文件testweb.95105813.cn.conf:server{ listen 443; server_name testweb.95105813.cn; ssl on; ssl_certificate /usr/local/nginx/ssls/testweb.95105813.cn.crt; ssl_certificate_key /usr/local/nginx/ssls/testweb.95105813.cn.key; ssl_protocols TLSv...
使用共享字典进行 SSL 轮换 共享字典最有效的用例之一是 SSL/TLS 轮换。使用js_shared_dict_zone时,无需重启 NGINX 就可更新 SSL/TLS 证书或密钥。此外,它还提供了一个类似 REST 的 API,可用于管理 NGINX 上的证书。 下面是一个 NGINX配置文件示例,该配置文件使用js_set和ssl_certificate指令来设置 HTTPS 服务...