咨询宝塔反代wordpress后台无法登录

查看 22|回复 0
作者:欧巴   
反代vps1宝塔,被反代wordpress 宝塔vps2,我用vps1反代了vps2,wordpress可以正常浏览,但是进入后台就不行,也按照搜索方法设置了vp1的反代规则
[ol]#PROXY-START/
location /
{
    #缓存媒体文件
    location ~* .jpg|.png|.gif|.jpeg|.ttf|.webp|.woff|.woff2|.ico$
    {
        proxy_set_header Host $host;
        proxy_set_header X-Real-IP $remote_addr;
        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
        proxy_set_header REMOTE-HOST $remote_addr;
        proxy_pass https://shopee6.flxzz.com;
        proxy_cache cache_one;
            proxy_cache_valid 30d;
        proxy_ignore_headers Cache-Control;
            add_header X-Cache "$upstream_cache_status from $server_addr";
    }
   
    #缓存css、js、html
     location ~* .css|.js|.html$
    {
        proxy_set_header Host $host;
        proxy_set_header X-Real-IP $remote_addr;
        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
        proxy_set_header REMOTE-HOST $remote_addr;
        proxy_pass https://shopee6.flxzz.com;
        proxy_cache cache_one;
            proxy_cache_valid 3d;
        proxy_ignore_headers Cache-Control;
            add_header X-Cache "$upstream_cache_status from $server_addr";
    }
   
    proxy_pass https://shopee6.flxzz.com;
    proxy_set_header Host $host;
    proxy_set_header X-Real-IP $remote_addr;
    proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
    proxy_set_header REMOTE-HOST $remote_addr;
   
    #持久化连接相关配置
    #proxy_connect_timeout 30s;
    #proxy_read_timeout 86400s;
    #proxy_send_timeout 30s;
    #proxy_http_version 1.1;
    #proxy_set_header Upgrade $http_upgrade;
    #proxy_set_header Connection "upgrade";
    #add_header X-Cache $upstream_cache_status;

    #expires 12h;
}
location /wp-admin {
proxy_pass https://shopee6.flxzz.com;
proxy_cache_valid any 0s;
}
#PROXY-END/[/ol]复制代码
域名替换了自己的,不让/wp-admin缓存,可是后台还是无法登录,哪里还有问题吗?

宝塔, 缓存, 后台

您需要登录后才可以回帖 登录 | 立即注册

返回顶部