Wang's blog Wang's blog
首页
  • 前端文章

    • HTML教程
    • CSS
    • JavaScript
  • 前端框架

    • Vue
    • React
    • VuePress
    • Electron
  • 后端技术

    • Npm
    • Node
    • TypeScript
  • 编程规范

    • 规范
  • 我的笔记
  • Git
  • GitHub
  • VSCode
  • Mac工具
  • 数据库
  • Google
  • 服务器
  • Python爬虫
  • 前端教程
更多
收藏
关于
  • 分类
  • 标签
  • 归档
GitHub (opens new window)

Wang Mings

跟随大神,成为大神!
首页
  • 前端文章

    • HTML教程
    • CSS
    • JavaScript
  • 前端框架

    • Vue
    • React
    • VuePress
    • Electron
  • 后端技术

    • Npm
    • Node
    • TypeScript
  • 编程规范

    • 规范
  • 我的笔记
  • Git
  • GitHub
  • VSCode
  • Mac工具
  • 数据库
  • Google
  • 服务器
  • Python爬虫
  • 前端教程
更多
收藏
关于
  • 分类
  • 标签
  • 归档
GitHub (opens new window)
  • Go

  • MD

  • Git

  • Image

  • GitHub

  • Google

  • VSCode

  • Mac工具

  • 数据库

  • 服务器

    • Linux

    • Nginx

      • Nginx反向代理配置
      • Nginx配置密码访问网页
    • Docker

  • 工具
  • 服务器
  • Nginx
wangmings
2022-07-19

Nginx反向代理配置

# Nginx 反向代理配置

location /{
    proxy_pass http://127.0.0.1:7002;   #反向代理,指向具体的node监听端口
    proxy_redirect     off;                           #关闭地址的重定向

    # 在代理请求头中加入下面的信息,方便我们用nodejs获取一些客户端信息
    proxy_set_header   Host             $host;        #本机地址(ip或域名)
    proxy_set_header   X-Real-IP        $remote_addr; #客户端真实ip
    proxy_set_header   X-Forwarded-For  $proxy_add_x_forwarded_for;#客户端真实ip
}
1
2
3
4
5
6
7
8
9
编辑 (opens new window)
Linuxexpect介绍和用法
Nginx配置密码访问网页

← Linuxexpect介绍和用法 Nginx配置密码访问网页→

最近更新
01
theme-vdoing-blog博客静态编译问题
09-16
02
搜索引擎
07-19
03
友情链接
07-19
更多文章>
Theme by Vdoing | Copyright © 2019-2025 Evan Xu | MIT License
  • 跟随系统
  • 浅色模式
  • 深色模式
  • 阅读模式
  • 主题模式