Yet another file download / upload with browser / app not working thread

Hi guys, im using seafile behind a nginx reverse proxy, but my app / web download and uploads are failing. Here are my config files:

nginx.conf

server {
        listen 80;
        server_name cloud.test.com;
        rewrite ^ https://$http_host$request_uri? permanent;
}

server {
        listen 443;
        ssl on;
        ssl_certificate /etc/letsencrypt/live/test.com/fullchain.pem;
        ssl_certificate_key /etc/letsencrypt/live/test.com/privkey.pem;
        server_name cloud.test.com;
        proxy_set_header X-Forwarded-For $remote_addr;

        add_header Strict-Transport-Security "max-age=31536000; includeSubDomains";
        server_tokens off;


        location / {
                fastcgi_pass    127.0.0.1:8000;
                fastcgi_param   SCRIPT_FILENAME     $document_root$fastcgi_script_name;
                fastcgi_param   PATH_INFO           $fastcgi_script_name;

                fastcgi_param   SERVER_PROTOCOL     $server_protocol;
                fastcgi_param   QUERY_STRING        $query_string;
                fastcgi_param   REQUEST_METHOD      $request_method;
                fastcgi_param   CONTENT_TYPE        $content_type;
                fastcgi_param   CONTENT_LENGTH      $content_length;
                fastcgi_param   SERVER_ADDR         $server_addr;
                fastcgi_param   SERVER_PORT         $server_port;
                fastcgi_param   SERVER_NAME         $server_name;
                fastcgi_param   REMOTE_ADDR         $remote_addr;

                fastcgi_param HTTPS on;
                fastcgi_param HTTP_SCHEME https;

                access_log      /var/log/nginx/seahub.access.log;
                error_log       /var/log/nginx/seahub.error.log;
                fastcgi_read_timeout 36000;
        }

        location /seafhttp {
                rewrite ^/seafhttp(.*)$ $1 break;
                proxy_pass http://127.0.0.1:8082;
                client_max_body_size 0;
                proxy_connect_timeout  36000s;
                proxy_read_timeout  36000s;
                proxy_send_timeout  36000s;
                send_timeout  36000s;
                proxy_request_buffering off;

        }

        location /media {
                root /srv/seafile/test.com/seafile-server/seahub;
        }
}

ccnet.conf

[General]
USER_NAME = test
ID = ....
NAME = test
SERVICE_URL = https://cloud.test.com

seafile.conf

[seahub]
port=8000
fastcgi=true

[network]
port=12001

[fileserver]
port=8082

seahub_settings.py

SECRET_KEY = '.....'
FILE_SERVER_ROOT = 'https://cloud.test.com/seafhttp'

I’ve followed multiple guides like

but none of them worked.

One thing should be that you are perhaps editing the location /media {} section…?

try leaving it as it was:

location /media {
    root /srv/seafile/seafile-server-latest/seahub;

seafile-server-latest should be the correct directory (at least it is on seafile <v6.0 … not sure about v6.xx

Usually you must not do this, unless you have a specific use case that I don’t know.

media has nothing to do with my problem, it contains the css and images etc for seahub but not the actual files

have you tried it with a selfsigned certificate for troubleshooting purposes?

openssl genrsa -out seafile.key 4096
openssl req -new -sha256 -key seafile.key -out seafile.csr
answer these:
County Name: US
then simply hit entet till coming to:
Common Name: type in your domain without https prefix: e.g. cloud.test.com

openssl x509 -req -sha256 -days 3650 -in seafile.csr -signkey seafile.key -out seafile.crt

point then to these certificates instead of your *.pem

EDIT
could you please be more specific about “my app / web download and uploads are failing” ?

  1. What does happen?
  2. Are you able to login to seahub?
  3. Are you able to login to android/iOS app?
  4. Does transfer start at all?
  5. Error message?
  6. Which seafile server version?
  7. ARM or x86 based server?

Use url with IP port 8000
and root IP 8082
pages admin