nginx反向代理https


证书生成:

windows下openssl安装,证书生成,nginx配置https以及http重定向https-YES开发框架网

nginx配置:

Markup 全选
server {
  listen 29110 ssl;
  # SSL 配置
  ssl_certificate ..\ssl\server.crt;
  ssl_certificate_key ..\ssl\server.key;


  gzip on;
  gzip_buffers 32 4K;
  gzip_comp_level 6;
  gzip_min_length 100;
  gzip_proxied any;
  gzip_types application/json text/plain text/xml text/css application/javascript application/x-javascript;
  gzip_vary on;
  gzip_http_version   1.0;
  gzip_disable "MSIE [1-6]\.(?!.*SV1)";

  # 设置上传文件的大小
  client_max_body_size 100m;

  # 后端服务
  location / {
    proxy_read_timeout 3600;  # 秒 20分钟 请求超时
    # 添加头部信息
    proxy_set_header Host $http_host;
    proxy_set_header X-Real-IP $remote_addr;
    proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
    proxy_set_header X-Forwarded-Proto $scheme;
    # 使用动态变量转发请求
    proxy_pass https://192.168.110.141;

	# 忽略证书验证
    proxy_ssl_verify off;
    proxy_ssl_trusted_certificate /dev/null;  # 或指定自签名证书路径,/dev/null 会忽略验证
  }
}

 

版权声明:本文为YES开发框架网发布内容,转载请附上原文出处连接
张国生
上一篇:windows下openssl安装,证书生成,nginx配置https以及http重定向https
下一篇:git批量克隆仓库代码以及批量上传
评论列表

发表评论

评论内容
昵称:
关联文章

nginx反向代理https
使用nuget-server搭建私有Nuget包服务器后,nginx反向代理无法下载包
nginx配置http自动重定向到https
windows下openssl安装,证书生成,nginx配置https以及http重定向https
nginx初始配置优化
宝塔系统 nginx位置记录
使用 mitmproxy + python 做拦截代理
Nginx部署
YARP+AgileConfig 5分钟实现一个支持配置热更新的代理网关
CentOS7 nginx SSL证书申请并自动续期
nginx websocket支持
nginx配置指南
nginx安装为windows服务
windows Nginx配置开机自启动
nginx集群中按照url规则指定节点访问
.NET Core 实现动态代理做AOP(面向切面编程)
CentOS安装nginx
Python Selenium Firefox 代理设置
nginx端口转发配置
C# HTTPHTTPS Get请求 和 Post 请求

联系我们
联系电话:15090125178(微信同号)
电子邮箱:garson_zhang@163.com
站长微信二维码
微信二维码