Only Office and NGINX redirect takes me to my homepage

Hello,

I am trying to install Only Office Server via this guide (installing via subfolder). I’m at the point where the document server is up and running, but i’m having problems adding it to nginx. Ideally, I’d like to redirect my.site/onlyofficeds to my document server, using https. I’m not just sure where to add the nginx info.

My best guess was, since I already have Seafile installed (yunohost version), I just used etc/nginx/conf.d/my.site.d/seafile.conf and this to it:

location /onlyofficeds/ {

    # THIS ONE IS IMPORTANT ! - Trailing slash !
    proxy_pass http://my.site:88/;

    proxy_http_version 1.1;
    client_max_body_size 100M; # Limit Document size to 100MB
    proxy_read_timeout 3600s;
    proxy_connect_timeout 3600s;
    proxy_set_header Upgrade $http_upgrade;
    proxy_set_header Connection $proxy_connection;

    # THIS ONE IS IMPORTANT ! - Subfolder and NO trailing slash !
    proxy_set_header X-Forwarded-Host $the_host/onlyofficeds;

    proxy_set_header X-Forwarded-Proto $the_scheme;
    proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
}

After restarting nginx, the redirect works, however it takes me to my yunohost homepage. I realize this is slightly outside the scope of Yunhost, but I’d appreciate any help on this matter.