Cant download file via browser

Hi I setup seafile on my raspi via docker-compose behind a nginx.
Everything works as expected via the seafile client, but I cant download files from my browser. And i get a 404 not found from nginx. So I assume there is the missconfiguration. The current configuration is now this

 server {
  listen 443 ssl;
  listen [::]:443 ssl;
  include snippets/self-signed.conf;
  include snippets/ssl-params.conf;

  server_name raspberrypi.seafile.local;

  proxy_set_header X-Forwarded-For $remote_addr;

  location / {
    proxy_pass http://localhost:8180;
    proxy_set_header Host $host:$server_port;
    proxy_set_header X-Real-IP $remote_addr;
    proxy_set_header X-Forwarded-Proto https;
    proxy_set_header   X-Forwarded-For $proxy_add_x_forwarded_for;
    proxy_set_header   X-Forwarded-Host $server_name;

    client_max_body_size 0;

    error_log       /var/log/nginx/seahub.error.log;
  }

  location /seafhttp {
        rewrite ^/seafhttp(.*)$ $1 break;
        proxy_pass http://127.0.0.1:8082;
        client_max_body_size 0;
     #   proxy_set_header   X-Forwarded-For $proxy_add_x_forwarded_for;

     #   proxy_connect_timeout  36000s;
     #   proxy_read_timeout  36000s;
     #   proxy_send_timeout  36000s;

     #   send_timeout  36000s;

        error_log       /var/log/nginx/seafhttp.error.log;
    }
    location /media {
        root /opt/seafile/seafile-server-latest/seahub;
    }

}

server {
  listen 80;
  listen [::]:80;

  server_name raspberrypi.seafile.local;
  rewrite ^ https://$http_host$request_uri? permanent;

  return 302 https://$server_name$request_uri;
}

Currently I am trying out things hence the commenting out lines. What am I doing wrong
I checked out this deploy_with_nginx documentation but it is still not working

What am I doing wrong?

Hey stefan1,
you definately have a misconfiguration either in your nginx configuration or in your seahub_settings.py.
Please check the nginx logs /var/log/nginx/error.log and /var/log/nginx/access.log and check that the folders are correct.
Is your seafile installed at /opt/seafile/?
Please post also your seahub_settings.py if you have any entries for SERVICE_URL.
Best regards
Christoph

Sorry for the late reply, I was busy the last few days.
I never touched a seahub_settings.py file. I launch seafile via docker-compose

Anyway in the “seafile system admin settings” I changed the
“SERVICE_URL” to <my.example.home>
“FILE_SERVER_ROOT” to <my.example.home/seafhttp>

with this nginx config it is working now

server {
  listen 443 ssl;
  listen [::]:443 ssl;
  include snippets/self-signed.conf;
  include snippets/ssl-params.conf;

  server_name my.example.home;
  location / {
    proxy_pass http://localhost:8180;
    proxy_set_header Host $host;
    proxy_set_header X-Real-IP $remote_addr;

    client_max_body_size 0;
  }

  location /seafhttp {
    rewrite ^/seafhttp(.*)$ $1 break;
    proxy_pass http://localhost:8082;

    client_max_body_size 0;
  }


}

server {
  listen 80;
  listen [::]:80;

  server_name my.example.home;

  return 302 https://$server_name$request_uri;
}