Kolab + Collabora?

Milan Petrovic petrovic.milan at gmail.com
Thu Sep 26 14:34:31 CEST 2019


Alexander, thanks a lot for the help!

I have found that I had the wrong $config['fileapi_wopi_office'] set. I
don't need the /hosting/discovery at the end of the URL. just the
Collabora's host name.

Now the editor opens (although, it looks like from the Manticore times),
but theerror is thrown that the file cannot be found ("Failed to read
document from storage"). So, I guess my Chwala settings should be somehow
updated.

I have put the rewrite rule (I'm using nginx, all of the Kolab is on the
same subdomain, Collabora uses another, both are on the same host):
'''
    location /chwala {
        index index.php;
        alias /usr/share/chwala/public_html;

        client_max_body_size 100M; # set maximum upload size

        # enable php
        location ~ .php$ {
            include fastcgi_params;
            fastcgi_param HTTPS on;
            fastcgi_pass
unix:/var/run/php-fpm/mail.mydomain.com_chwala.sock;
            fastcgi_param SCRIPT_FILENAME $request_filename;
            # Without this, PHPSESSION is replaced by webadmin-api
X-Session-Token
            fastcgi_param PHP_VALUE "session.auto_start=0
                session.use_cookies=0";
            fastcgi_pass_header X-Session-Token;
        }
        location /chwala/api {
            rewrite ^/chwala/api/wopi/(.*)$
/chwala/api/index.php?wopi=1&method=$1 break;
        }
    }
'''
loolwsd service throws the following:

Sep 26 14:25:23 mail.mydomain.com loolwsd[4957]: wsd-04957-09382 2019-09-26
12:25:23.157369 [ docbroker_019 ] ERR  WOPI::CheckFileInfo failed with 500
Internal Server Error| wsd/Storage.cpp:495
Sep 26 14:25:23 mail.mydomain.com loolwsd[4957]: wsd-04957-09382 2019-09-26
12:25:23.158112 [ docbroker_019 ] ERR  loading document exception:
WOPI::CheckFileInfo failed| wsd/DocumentBroker.cpp:1158
Sep 26 14:25:23 mail.mydomain.com loolwsd[4957]: wsd-04957-09382 2019-09-26
12:25:23.158135 [ docbroker_019 ] ERR  Failed to add session to
[/chwala/api/wopi/files/w-OEA7dCZ70b5mV7XW] with URI [
https://mail.mydomain.com/chwala/api/wopi/files/w-OEA7dCZ70b5mV7XW?access_token=HCMTvTP7oh3xXOrLpeyvwslKSR&access_token_ttl=1569511521000&permission=edit]:
WOPI::CheckFileInfo failed| wsd/DocumentBroker.cpp:1120
Sep 26 14:25:23 mail.mydomain.com loolwsd[4957]: wsd-04957-09382 2019-09-26
12:25:23.270254 [ docbroker_019 ] WRN  Child session [01b0] not found to
forward message: load url=
https://mail.mydomain.com/chwala/api/wopi/files/w-OEA7dCZ70b5mV7XW?access_token=HCMTvTP7oh3xXOrLpeyvwslKSR&access_token_ttl=1569511521000&permission=edit
readonly=0 lang=en-US| wsd/DocumentBroker.cpp:1770
Sep 26 14:25:23 mail.mydomain.com loolwsd[4957]: wsd-04957-09382 2019-09-26
12:25:23.289352 [ docbroker_019 ] ERR  Invalid or unknown session [01b0] to
remove.| wsd/DocumentBroker.cpp:1194
Sep 26 14:25:24 mail.mydomain.com loolwsd[4957]: wsd-04957-04963 2019-09-26
12:25:24.159340 [ prisoner_poll ] WRN  Prisoner connection disconnected but
without valid socket.| wsd/LOOLWSD.cpp:1799
Sep 26 14:25:24 mail.mydomain.com loolwsd[4957]: kit-09330-04964 2019-09-26
12:25:24.159425 [ loolkit ] WRN  Kit connection lost without exit arriving
from wsd. Setting TerminationFlag| kit/Kit.cpp:2241

Also, my "fileapi_wopi_service" and "file_api_url" are the same, not sure
if that should be the case:

    $config['fileapi_wopi_service'] = '
https://mail.ifi-experience.com/chwala/api';

    $config['file_api_url'] = 'https://mail.ifi-experience.com/chwala/api';



On Thu, Sep 26, 2019 at 7:40 AM Aleksander Machniak <machniak at kolabsys.com>
wrote:

> On 9/25/19 1:01 PM, Milan Petrovic wrote:
> > Anyone?
> > Any hint?
>
> In recent Kolab you don't need kolab-wopi, it has been replaced by code
> built into chwala.
>
> I never used CODE, but I work with collabora official (partner) packages.
>
> 1. You have to configure chwala to talk to collabora
>
> // WOPI/Office service URL. Enables use of collaborative editor supporting
> WOPI.
> // Note: this URL should be accessible from Chwala host and Roundcube host
> as well.
> $config['fileapi_wopi_office'] = null;
>
> You need also this rule in http server:
>
> RewriteRule ^api/wopi/(.*)$ api/index.php?wopi=1&method=$1 [L,QSA]
>
> 2. You have to configure collabora to allow Chwala host.
>
> That's it. Note that Roundcube (kolab_files plugin) is talking to chwala.
> Chwala is
> talking to Collabora. Collabora is talking to Chwala. User browser is
> talking to
> Roundcube, Chwala and Collabora.
>
> That's why it is important to carefully setup DNS so hostnames are
> resolvable properly on
> server as well as on client-side. Also, be carefull with ssl certificates
> and
> cross-domain, etc. Look for errors on server (Roundcube, Chwala,
> Collabora), but also in
> the web browser console.
>
> Also note that some chwala capabilities are cached in session, so you
> sometimes have to
> re-login in Roundcube to notice changes. You may also unset
> $config['fileapi_cache'] while
> debugging.
>
> --
> Aleksander Machniak
> Senior Software Engineer
> Kolab Systems AG: https://kolabsystems.com
> PGP: 19359DC1
> _______________________________________________
> users mailing list
> users at lists.kolab.org
> https://lists.kolab.org/mailman/listinfo/users
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.kolab.org/pipermail/users/attachments/20190926/d0836cdb/attachment-0001.html>


More information about the users mailing list