Websoft9 / docker-library

Docker Compose examples of selfhosted FOSS based on official image, just run it.
https://www.websoft9.com
Other
30 stars 14 forks source link

华为云L实例Portainer的Nginx配置问题 #607

Closed zhaojing1987 closed 1 month ago

zhaojing1987 commented 2 months ago

Nginx的配置有问题,导致有些Portainer操作的权限不够,报403错误

<html> <head><title>403 Forbidden</title></head> <body> <center><h1>403 Forbidden</h1></center> <hr><center>nginx</center> </body> </html>

现在修改了Nginx的配置为:

location / {
      proxy_set_header Host $host;
      proxy_set_header X-Forwarded-Scheme $scheme;
      proxy_set_header X-Forwarded-Proto  $scheme;
      proxy_set_header X-Forwarded-For    $remote_addr;
      proxy_set_header X-Real-IP        $remote_addr;
      proxy_set_header Accept-Encoding \"\";
      proxy_pass  http://127.0.0.1:9091;
      proxy_set_header Upgrade $http_upgrade;
      proxy_set_header Connection $http_connection;
   }

测试可用。

chendelin1982 commented 2 months ago

test Portainer at Websoft9 Appstore

qiaofeng1227 commented 1 month ago

在软件商店下安装portainer重现编排后一切功能正常