N

Nginx 镜像网站

600.one 默认分类 2024-10-31
map $host $mirror_host {
  www.600.one www.googe.com;
  default "";
}

server {
    listen 80;
    listen 443 ssl;

    server_name xray.600.one;

    ssl_certificate ssl/www.600.one/fullchain.cer;
    ssl_certificate_key ssl/www.600.one/www.600.one.key;

    resolver 8.8.8.8 ipv6=off;

    proxy_ssl_server_name on;

    proxy_set_header Host "$proxy_host";

    location / {
      if ( "$mirror_host" = "" ) {
        return 404;
      }

      proxy_redirect https://$proxy_host https://$host;

      proxy_pass "${scheme}://${mirror_host}";
    }
}

转自 https://blog.csdn.net/lin2ur/article/details/140442039

评论(0)

发布评论