upstream frontends {
    server 127.0.0.1:8080;
}
server {
    server_name _;
    location / {
            proxy_pass_header Server;
            proxy_set_header Host $http_host;
            proxy_redirect off;
            proxy_set_header X-Real-IP $remote_addr;
            proxy_set_header X-Scheme $scheme;
            proxy_pass http://frontends;
      }
}

8080为Golang监听的端口

results matching ""

    No results matching ""