server {
        listen       8888;
        server_name  localhost;

        #charset koi8-r;

        #access_log  logs/host.access.log  main;

        location / {
            root   html;
            index  index.html index.htm index.jsp;
            proxy_pass http://xx.xx.xx.xx:xxxx;
            proxy_set_header           Host $host;
            proxy_set_header           X-Real-IP $remote_addr;
            proxy_set_header           X-Forwarded-For $proxy_add_x_forwarded_for;       
        }

 

在局域网中网段隔离 ,需网段1访问网段2网站,此时需要把nginx架设到一台有内外网的中间机上,通过修改nginx.conf文件(nginx下conf文件夹中)能实现网段1访问中间服务器实现对网段2的跳转访问。

 

相关文章:

  • 2021-12-01
  • 2021-11-14
  • 2022-12-23
  • 2021-05-18
猜你喜欢
  • 2021-11-27
  • 2021-12-22
  • 2022-01-16
  • 2021-11-21
相关资源
相似解决方案