# Collabora plugin on Cells

**URL:** <https://forum.pydio.com/t/collabora-plugin-on-cells/4614>\
**Category:** Pydio Cells\
**Tags:** plugins, docker\
**Created:** [July 25, 2022, 7:50am UTC](https://forum.pydio.com/t/collabora-plugin-on-cells/4614 "2022-07-25T07:50:43Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![corvo](https://avatars.discourse-cdn.com/v4/letter/c/c89c15/32.png) [@corvo](https://forum.pydio.com/u/corvo)\
**Post date:** [July 25, 2022, 7:50am UTC](https://forum.pydio.com/t/collabora-plugin-on-cells/4614/1 "2022-07-25T07:50:43Z")

</div>

Hi all,

I’m setting up the plugin of Collabora Online, but I’m facing issues in making it work.

Setup on Pydio Cells side:

- Pydio Cells conteinerized with Docker and behind an Nginx 1.14.1 reverse proxy
- Collabora Code version: 21 and upper
- LibreOffice use SSL: yes
- LibreOffice Host: my-libreoffice-host.mydomain
- LibreOffice Host Port: 9980

Setup on Collabora server side:

- Collabora conteinerized with Podman and behind an Nginx 1.20.1 reverse proxy
- reverse proxy rules as reported by [Proxy settings — SDK https://sdk.collaboraonline.com/ documentation](https://sdk.collaboraonline.com/docs/installation/Proxy_settings.html)

```auto
# static files
 location ^~ /browser {
   proxy_pass https://127.0.0.1:9980;
   proxy_set_header Host $host;
   proxy_set_header X-Forwarded-Proto $scheme;
 }

 location ^~ /browser/dist/cool.html {
   proxy_pass https://127.0.0.1:9980;
   proxy_set_header Host $host;
   proxy_set_header X-Forwarded-Proto $scheme;
 }

 # WOPI discovery URL
 location ^~ /hosting/discovery {
   proxy_pass https://127.0.0.1:9980;
   proxy_set_header Host $host;
   proxy_set_header X-Forwarded-Proto $scheme;
 }

 # Capabilities
 location ^~ /hosting/capabilities {
   proxy_pass https://127.0.0.1:9980;
   proxy_set_header Host $host;
   proxy_set_header X-Forwarded-Proto $scheme;
 }

 # main websocket
 location ~ ^/cool/(.*)/ws$ {
   proxy_pass https://127.0.0.1:9980;
   proxy_set_header Upgrade $http_upgrade;
   proxy_set_header Connection "Upgrade";
   proxy_set_header Host $host;
   proxy_set_header X-Forwarded-Proto $scheme;
   proxy_read_timeout 36000s;
 }

 # download, presentation and image upload
 location ~ ^/(c|l)ool {
   proxy_pass https://127.0.0.1:9980;
   proxy_set_header Host $host;
   proxy_set_header X-Forwarded-Proto $scheme;
 }

 # Admin Console websocket
 location ^~ /cool/adminws {
   proxy_pass https://127.0.0.1:9980;
   proxy_set_header Upgrade $http_upgrade;
   proxy_set_header Connection "Upgrade";
   proxy_set_header Host $host;
   proxy_set_header X-Forwarded-Proto $scheme;
   proxy_read_timeout 36000s;
 }

```

When I try to open a word doc in Pydio Cells, I get a “502 bad gateway” error. So I decided to delete the Host Port configuration data, that is delete 9980 in the Collabora Plugin configuration, despite the fact that the value cannot be empty.  
This time I don’t get the 502 error, but nothing happens. Looking at the logs, I see that Cells is asking for this URI:

```auto
"GET /browser/dist/cool.html?host=wss://pydiocells.infn.it&WOPISrc=https%3A%2F%2Fpydiocells.infn.it%2Fwopi%2Ffiles%2Ff853eb71-36fe-405d-bfa6-3714d870ea3f&access_token=VTN1sg3pYU2q0cIcIIFyVQMdUPR6pmOrzzZ5vjBX_F0.2dYVuOzHkIyLxiYdjhKOFw_8dLQ19zkJ0_nFXSFl880&permission=edit HTTP/2.0" 200 28128 "https://pydiocells.infn.it/ws-personal-files/" "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:102.0) Gecko/20100101 Firefox/102.0" "-"

```

The Nginx reverse proxy on Collabora side gets the request:

```auto
 "GET /browser/dist/cool.html?host=wss://pydiocells.infn.it&WOPISrc=https%3A%2F%2Fpydiocells.infn.it%2Fwopi%2Ffiles%2Ff853eb71-36fe-405d-bfa6-3714d870ea3f&access_token=VTN1sg3pYU2q0cIcIIFyVQMdUPR6pmOrzzZ5vjBX_F0.2dYVuOzHkIyLxiYdjhKOFw_8dLQ19zkJ0_nFXSFl880&permission=edit HTTP/1.1" 200 28128 "https://pydiocells.infn.it/ws-personal-files/" "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:102.0) Gecko/20100101 Firefox/102.0" "10.88.0.1"

```

Collabora itself gets the request:

```auto
 Handling request: /browser/dist/cool.html?host=wss://pydiocells.infn.it&WOPISrc=https%3A%2F%2Fpydiocells.infn.it%2Fwopi%2Ffiles%2Ff853eb71-36fe-405d-bfa6-3714d870ea3f&access_token=VTN1sg3pYU2q0cIcIIFyVQMdUPR6pmOrzzZ5vjBX_F0.2dYVuOzHkIyLxiYdjhKOFw_8dLQ19zkJ0_nFXSFl880&permission=edit| wsd/COOLWSD.cpp:3416

```

and starts to process it. Still nothing happens on Cells side, and no document is loaded.  
If I try to make a request directly from my browser, that is if I put the complete URL on my Chrome/Firefox browser like this:

```auto
https://my-libreoffice-host.mydomain/browser/dist/cool.html?host=wss://pydiocells.infn.it&WOPISrc=https%3A%2F%2Fpydiocells.infn.it%2Fwopi%2Ffiles%2Ff853eb71-36fe-405d-bfa6-3714d870ea3f&access_token=VTN1sg3pYU2q0cIcIIFyVQMdUPR6pmOrzzZ5vjBX_F0.2dYVuOzHkIyLxiYdjhKOFw_8dLQ19zkJ0_nFXSFl880&permission=edit

```

it works and I can see and edit the document.

The only thing I can get from Collabora logs is this error, while it is processing the request from Cells:

```auto
 [websrv_poll] ERR #30 Exception while processing incoming request: [GET /cool/https%3A%2F%2Fpydiocells.infn.it%2Fwopi%2Ffiles%2Ff853eb71-36fe-405d-bfa6-3714d870ea3f%3Faccess_token%3DVTN1sg3pYU2q0cIcIIFyVQMdUPR6pmOrzzZ5vjBX_F0.2dYVuOzHkIyLxiYdjhKOFw_8dLQ19zkJ0_nFXSFl880%26access_token_ttl%3D0/ws?WOPISrc=https%3A%2F%2Fpydiocells.infn.it%2Fwopi%2Ffiles%2Ff853eb71-36fe-405d-bfa6-3714d870ea3f&compat=/ws HTTP/1.0^M...]: Invalid or unknown request.| wsd/COOLWSD.cpp:3570

```

Note that I don’t have this error when asking the URL directly from my browser and not passing through Cells. Given this behaviour, I’m sort of thinking that the issue is on Cells side and not on Collabora one.

Any help is appreciated.

Regards,

Marco Corvo

---

<div class="post-metadata">

**Author:** ![c12simple](https://yyz2.discourse-cdn.com/flex032/user_avatar/forum.pydio.com/c12simple/32/90_2.png) [@c12simple](https://forum.pydio.com/u/c12simple)\
**Post date:** [August 1, 2022, 2:02pm UTC](https://forum.pydio.com/t/collabora-plugin-on-cells/4614/2 "2022-08-01T14:02:01Z")

</div>

> [@corvo](#):
>
> ```auto
> # main websocket
> location ~ ^/cool/(.*)/ws$ {
> proxy_pass https://cellsdomain:cellsport(443 not 9980);
> proxy_set_header Upgrade $http_upgrade;
> proxy_set_header Connection "Upgrade";
> proxy_set_header Host $host;
> proxy_set_header X-Forwarded-Proto $scheme;
> proxy_read_timeout 36000s;
> }
> 
> # download, presentation and image upload
> location ~ ^/(c|l)ool {
> proxy_pass https://cellsdomain:cellsport(443 not 9980);
> proxy_set_header Host $host;
> proxy_set_header X-Forwarded-Proto $scheme;
> }
> 
> ```

Try to add above section into nginx config of cells  
(

> [@corvo](#):
>
> Pydio Cells conteinerized with Docker and behind an Nginx 1.14.1 reverse proxy

)

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex032/uploads/pydio/original/2X/6/61f19fa52ec15fd4250db51aea351adba0e831fd.png) [@system](https://forum.pydio.com/u/system)\
**Post date:** [September 30, 2022, 2:02pm UTC](https://forum.pydio.com/t/collabora-plugin-on-cells/4614/3 "2022-09-30T14:02:57Z")

</div>

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.
