Collabora (docker) and nginx - error 404

Hi,

I have a simple nextcloud installation using official tarball (no docker, no snap, no distribution package). Since months I use the docker collabora version with nextcloud successfully until collabora 6.4 version.

Now with the latest 21.1 collabora version, it seems I have to change my nginx conf but I don’t know how. Docker collabora starts successfully.

# curl -k https://127.0.0.1:9980
OK

collabora-nextcloud

But I have a 404 error when opening a document in nextcloud.

Here is my nginx config:

server {
  listen       443 ssl http2;
  server_name  collabora.example.org;

  ssl_certificate /etc/letsencrypt/live/example.org/fullchain.pem;
  ssl_certificate_key /etc/letsencrypt/live/example.org/privkey.pem;
  ssl_certificate /etc/letsencrypt/live/example.org_ecc/fullchain.pem;
  ssl_certificate_key /etc/letsencrypt/live/example.org_ecc/privkey.pem;
  include conf.d/common-ssl.conf;
  
  # static files
  location ^~ /loleaflet {
    proxy_pass https://localhost:9980;
    proxy_set_header Host $http_host;
  }

  # WOPI discovery URL
  location ^~ /hosting/discovery {
    proxy_pass https://localhost:9980;
    proxy_set_header Host $http_host;
  }

  # Capabilities
  location ^~ /hosting/capabilities {
    proxy_pass https://localhost:9980;
    proxy_set_header Host $http_host;
  }

 # main websocket
	location ~ ^/lool/(.*)/ws$ {
  	proxy_pass https://localhost:9980;
		proxy_set_header Upgrade $http_upgrade;
    proxy_set_header Connection "Upgrade";
    proxy_set_header Host $http_host;
    proxy_read_timeout 36000s;
 }
 
 # download, presentation and image upload
 	location ~ ^/lool {
    proxy_pass https://localhost:9980;
    proxy_set_header Host $http_host;
 }
 
 # Admin Console websocket
 	location ^~ /lool/adminws {
    proxy_pass https://localhost:9980;
    proxy_set_header Upgrade $http_upgrade;
    proxy_set_header Connection "Upgrade";
    proxy_set_header Host $http_host;
    proxy_read_timeout 36000s;
 	}
}

Here is my nginx log:

192.168.1.156 - collabora.example.org - - [26/Jan/2022:11:48:56 +0100] - TLSv1.3 - TLS_AES_256_GCM_SHA384 - "POST /browser/739da71/cool.html?WOPISrc=https%3A%2F%2Fcloud.example.org%2Findex.php%2Fapps%2Frichdocuments%2Fwopi%2Ffiles%2F1403_ocekbocopwb4&title=Nouveau%20document.odt&lang=fr&closebutton=1&revisionhistory=1 HTTP/2.0" 404 146 "-" "Mozilla/5.0 (X11; Linux x86_64; rv:96.0) Gecko/20100101 Firefox/96.0" "-"

2022/01/26 12:01:53 [error] 1475#0: *211 open() "/usr/html/browser/739da71/cool.html" failed (2: No such file or directory), client: 192.168.1.156, server: collabora.example.org, request: "POST /browser/739da71/cool.html?WOPISrc=https%3A%2F%2Fcloud.example.org%2Findex.php%2Fapps%2Frichdocuments%2Fwopi%2Ffiles%2F5496_ocekbocopwb4&title=Mon%20-fichier.odt&lang=fr&closebutton=1&revisionhistory=1 HTTP/2.0", host: "collabora.example.org"

Do you see anything wrong? What can information can I give you to help me?

HI Tom,

I Have the same issue. did you ever resolve this?

Hi, no I didn’t. But now I don’t use collabora with docker anymore. I use the Collabora CODE app. It works fine!