• Nginx反向代理配置


    80端口反向代理配置:

    server {
            listen       80 ;
            server_name  xx.abc.com;
            root         /usr/share/nginx/html;
    
            include /etc/nginx/default.d/*.conf;
    
            location / {
              proxy_set_header X-Real-IP $remote_addr;
              proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
              proxy_set_header Host $http_host;
              proxy_set_header X-NginX-Proxy true;
              proxy_pass http://127.0.0.1:8082;
              proxy_redirect off;
              proxy_http_version 1.1;
              proxy_set_header Upgrade $http_upgrade;
              proxy_set_header Connection "upgrade";
              proxy_redirect off;
              proxy_set_header X-Forwarded-Proto $scheme;
            }
        }

    443端口反向代理配置:

    server {
        listen       443;
        server_name  xcx.abc.com;
        ssl on;
        root html;
        index index.html index.htm;
        ssl_certificate      "/etc/nginx/cert_xcx/214448276670131.pem";
        ssl_certificate_key  "/etc/nginx/cert_xcx/214448276670131.key";
    
        ssl_session_cache    shared:SSL:1m;
        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;
    
        location / {
          proxy_set_header X-Real-IP $remote_addr;
          proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
          proxy_set_header Host $http_host;
          proxy_set_header X-NginX-Proxy true;
          proxy_pass http://127.0.0.1:8080;
          proxy_redirect off;
          proxy_http_version 1.1;
          proxy_set_header Upgrade $http_upgrade;
          proxy_set_header Connection "upgrade";
          proxy_redirect off;
          proxy_set_header X-Forwarded-Proto $scheme; 
        }
      }
  • 相关阅读:
    [Leetcode] ZigZag Conversion
    [Leetcode] Wildcard Matching
    [Leetcode] 4Sum
    [Leetcode] Word Break II
    [Leetcode] Best Time to Buy and Sell Stock III
    [Leetcode] Permutation Sequence
    [Leetcode] Surrounded Regions
    [Jobdu] 题目1522:包含min函数的栈
    CUDA2.1-原理之索引与warp
    opencv8-GPU之相似性计算
  • 原文地址:https://www.cnblogs.com/beyang/p/9505249.html
Copyright © 2020-2023  润新知