Problem with Collabora

@Lars_M how did you install your Docker?

not your docker startup. you should verify you vhost config for apache reverse proxy.

VirtualHost *:443
ServerName host.domain.tld:443

/VirtualHost

your docker startup should be:

docker run -t -d -p 127.0.0.1:9980:9980 -e ‘domain=cloudhost.domain.tld’ --restart always --cap-add MKNOD collabora/code

yes it´s listening to 127.0.0.1:9980 and cloud.domain.tld that is not my problem.
when i enter the URL manually i get this:

https://cloud.domain.tld/loleaflet/2.0.1/loleaflet.html

and /hosting/discovery

i get the XML Part

docker logs:

root@panel:/boot# docker logs 6f30c379fc5d                                                                   
Generating RSA private key, 2048 bit long modulus                                                            
.....................................................................................................+++     
..+++                                                                                                        
e is 65537 (0x10001)                                                                                         
Generating RSA private key, 2048 bit long modulus                                                            
.+++                                                                                                         
...................................................................................+++                       
e is 65537 (0x10001)                                                                                         
Signature ok                                                                                                 
subject=/C=DE/ST=BW/L=Stuttgart/O=Dummy Authority/CN=localhost                                               
Getting CA Private Key                                                                                       
loolforkit version details: 2.0.1 - 2.0.1                                                                    
office version details: { "ProductName": "Collabora Office", "ProductVersion": "5.1", "ProductExtension": ".1
0.15", "BuildId": "345fa14e85e6e36ad0280f4e549c70f6b9af1a18" }                                               
Generating RSA private key, 2048 bit long modulus                                                            
............+++                                                                                              
...............................+++                                                                           
e is 65537 (0x10001)                                                                                         
Generating RSA private key, 2048 bit long modulus                                                            
................+++                                                                                          
.............................................+++                                                             
e is 65537 (0x10001)                                                                                         
Signature ok                                                                                                 
subject=/C=DE/ST=BW/L=Stuttgart/O=Dummy Authority/CN=localhost                                               
Getting CA Private Key                                                                                       
loolforkit version details: 2.0.1 - 2.0.1                                                                    
office version details: { "ProductName": "Collabora Office", "ProductVersion": "5.1", "ProductExtension": ".1
0.15", "BuildId": "345fa14e85e6e36ad0280f4e549c70f6b9af1a18" }                                               
wsd-00026-0030 0:32:52.769170 [ client_ws_0001 ] ERR  ClientRequestHandler::handleClientRequest: Exception: I
nvalid URI.| wsd/LOOLWSD.cpp:1226                                                                            
wsd-00026-0031 0:32:59.263053 [ client_ws_0002 ] ERR  ClientRequestHandler::handleClientRequest: Exception: I
nvalid URI.| wsd/LOOLWSD.cpp:1226                                                                            
wsd-00026-0030 0:33:14.262702 [ client_ws_0003 ] ERR  ClientRequestHandler::handleClientRequest: Exception: I
nvalid URI.| wsd/LOOLWSD.cpp:1226

Just a little question. Is it possible to launch CollaBora without docker?
Docker with a LXC or OVZ Container won’t work correctly or am I wrong?

look here: [HOWTO] Collabora 2.0 without using Docker not for prod

you should have two different host

cloudhost
officehost (docker image)

docker should run with connection to cloudhost not officehost

docker run -t -d -p 127.0.0.1:9980:9980 -e ‘domain=cloudhost.domain.tld’ --restart always --cap-add MKNOD collabora/code

you are starting the docker image with officehost as full domainname

the connection to officehost will be done with reverse proxy

I using one host for both collabora and Nextcloud

you do not understand.

Hardware-Host: cloudserver
Virtual-Host: officeserver in docker container

apache reverse proxy:
cloudserver:443 -> locahost:443
officeserver:443 -> localhost:9980

Hi,
have you resolved your problem?
show your config php, i wanna compare with mine config.php

sorry for late reponse.
This is my apache proxy config:
The SSL Cert Path is deleted. I use Plesk Onyx.

 # SSL configuration, you may want to take the easy route instead and use Lets Encrypt!
  SSLEngine on
  SSLProtocol             all -SSLv2 -SSLv3
  SSLCipherSuite ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305:ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384:DHE-RSA-AES128-GCM-SHA256:DHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-AES128-SHA256:ECDHE-RSA-AES128-SHA256:ECDHE-ECDSA-AES128-SHA:ECDHE-RSA-AES256-SHA384:ECDHE-RSA-AES128-SHA:ECDHE-ECDSA-AES256-SHA384:ECDHE-ECDSA-AES256-SHA:ECDHE-RSA-AES256-SHA:DHE-RSA-AES128-SHA256:DHE-RSA-AES128-SHA:DHE-RSA-AES256-SHA256:DHE-RSA-AES256-SHA:ECDHE-ECDSA-DES-CBC3-SHA:ECDHE-RSA-DES-CBC3-SHA:EDH-RSA-DES-CBC3-SHA:AES128-GCM-SHA256:AES256-GCM-SHA384:AES128-SHA256:AES256-SHA256:AES128-SHA:AES256-SHA:DES-CBC3-SHA:!DSS
  SSLHonorCipherOrder     on

  # Encoded slashes need to be allowed
  AllowEncodedSlashes NoDecode

  # Container uses a unique non-signed certificate
  SSLProxyEngine On
  SSLProxyVerify None
  SSLProxyCheckPeerCN Off
  SSLProxyCheckPeerName Off

  # keep the host
  ProxyPreserveHost On

  # static html, js, images, etc. served from loolwsd
  # loleaflet is the client part of LibreOffice Online
  ProxyPass           /loleaflet https://127.0.0.1:9980/loleaflet retry=0
  ProxyPassReverse    /loleaflet https://127.0.0.1:9980/loleaflet

  # WOPI discovery URL
  ProxyPass           /hosting/discovery https://127.0.0.1:9980/hosting/discovery retry=0
  ProxyPassReverse    /hosting/discovery https://127.0.0.1:9980/hosting/discovery

  # Main websocket
  ProxyPassMatch "/lool/(.*)/ws$" wss://127.0.0.1:9980/lool/$1/ws nocanon

  # Admin Console websocket
  ProxyPass   /lool/adminws wss://127.0.0.1:9980/lool/adminws

  # Download as, Fullscreen presentation and Image upload operations
  ProxyPass           /lool https://127.0.0.1:9980/lool
  ProxyPassReverse    /lool https://127.0.0.1:9980/lool

Maybe this helps?

[ client_ws_0001 ] ERR ClientRequestHandler::handleClientRequest: Exception: Invalid URI.| wsd/LOOLWSD.cpp:1245

Google Chrome Error Console:

WebSocket connection to 'wss://office.domain.tld/lool/%3Fpermission%3Dedit/ws' failed: Invalid frame header

I have this found at the logs.


Errorno app in context2017-02-02T12:05:49+0100
OCP\AppFramework\QueryException: Could not resolve OCA\Richdocuments\Settings\Section! Class OCA\Richdocuments\Settings\Section does not exist
Errorno app in context2017-02-02T12:05:40+0100
OCP\AppFramework\QueryException: Could not resolve OCA\Richdocuments\Settings\Section! Class OCA\Richdocuments\Settings\Section does not exist
Errorno app in context2017-02-01T22:36:19+0100
OCP\AppFramework\QueryException: Could not resolve OCA\Richdocuments\Settings\Section! Class OCA\Richdocuments\Settings\Section does not exist
Errorno app in context2017-02-01T20:22:49+0100
OCP\AppFramework\QueryException: Could not resolve OCA\Richdocuments\Settings\Section! Class OCA\Richdocuments\Settings\Section does not exist
Errorno app in context2017-02-01T20:22:28+0100
OCP\AppFramework\QueryException: Could not resolve OCA\Richdocuments\Settings\Section! Class OCA\Richdocuments\Settings\Section does not exist
/var/www/vhosts/domain.tld/nextcloud/lib/private/AppFramework/Utility/SimpleContainer.php - line 117: OC\AppFramework\Utility\SimpleContainer->resolve('OCA\\Richdocumen...')
/var/www/vhosts/domain.tld/nextcloud/lib/private/ServerContainer.php - line 89: OC\AppFramework\Utility\SimpleContainer->query('OCA\\Richdocumen...')
/var/www/vhosts/domain.tld/nextcloud/lib/private/Settings/Manager.php - line 319: OC\ServerContainer->query('OCA\\Richdocumen...')
/var/www/vhosts/domain.tld/nextcloud/lib/private/Settings/Manager.php - line 353: OC\Settings\Manager->query('OCA\\Richdocumen...')
/var/www/vhosts/domain.tld/nextcloud/settings/Controller/AdminSettingsController.php - line 131: OC\Settings\Manager->getAdminSections()
/var/www/vhosts/domain.tld/nextcloud/settings/Controller/AdminSettingsController.php - line 70: OC\Settings\Controller\AdminSettingsController->getNavigationParameters('server')
[internal function] OC\Settings\Controller\AdminSettingsController->index('server')
/var/www/vhosts/domain.tld/nextcloud/lib/private/AppFramework/Http/Dispatcher.php - line 160: call_user_func_array(Array, Array)
/var/www/vhosts/domain.tld/nextcloud/lib/private/AppFramework/Http/Dispatcher.php - line 90: OC\AppFramework\Http\Dispatcher->executeController(Object(OC\Settings\Controller\AdminSettingsController), 'index')
/var/www/vhosts/domain.tld/nextcloud/lib/private/AppFramework/App.php - line 114: OC\AppFramework\Http\Dispatcher->dispatch(Object(OC\Settings\Controller\AdminSettingsController), 'index')
/var/www/vhosts/domain.tld/nextcloud/lib/private/AppFramework/Routing/RouteActionHandler.php - line 47: OC\AppFramework\App main('OC\\Settings\\Con...', 'index', Object(OC\AppFramework\DependencyInjection\DIContainer), Array)
[internal function] OC\AppFramework\Routing\RouteActionHandler->__invoke(Array)
/var/www/vhosts/domain.tld/nextcloud/lib/private/Route/Router.php - line 299: call_user_func(Object(OC\AppFramework\Routing\RouteActionHandler), Array)
/var/www/vhosts/domain.tld/nextcloud/lib/base.php - line 1010: OC\Route\Router->match('/settings/admin')
/var/www/vhosts/domain.tld/nextcloud/index.php - line 40: OC handleRequest()
{main}

Shouldn’t it be:
docker run -t -d -p 127.0.0.1:9980:9980 -e ‘domain=cloudhost\\.domain\\.tld’ --restart always --cap-add MKNOD collabora/code

(Sorry if this has been brought up already…)

hmm no i get this error when i acces one doc file and the “permission denied” message appears.

2017-02-05 10:42:38	Error			(111)Connection refused: AH00957: HTTPS: attempt to connect to 127.0.0.1:9980 (127.0.0.1) failed				Apache-Fehler
2017-02-05 10:42:38	Error			AH00959: ap_proxy_connect_backend disabling worker for (127.0.0.1) for 0s				Apache-Fehler
2017-02-05 10:42:38	Error	5.10.188.170		AH01114: HTTP: failed to make connection to backend: 127.0.0.1				Apache-Fehler
2017-02-05 10:42:42	Error	5.10.188.170	503	GET /hosting/discovery HTTP/1.1		Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/55.0.2883.87 Safari/537.36	1.47 K	SSL/TLS-Zugriff für Apache
2017-02-05 10:42:42	Error			(111)Connection refused: AH00957: HTTPS: attempt to connect to 127.0.0.1:9980 (127.0.0.1) failed				Apache-Fehler
2017-02-05 10:42:42	Error			AH00959: ap_proxy_connect_backend disabling worker for (127.0.0.1) for 0s				Apache-Fehler
2017-02-05 10:42:42	Error	5.10.188.170		AH01114: HTTP: failed to make connection to backend: 127.0.0.1				Apache-Fehler
2017-02-05 10:43:39	Error	5.10.188.170	502	GET /hosting/discovery HTTP/1.1		Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/55.0.2883.87 Safari/537.36	1.56 K	SSL/TLS-Zugriff für Apache
2017-02-05 10:43:39	Error	5.10.188.170		(103)Software caused connection abort: AH01102: error reading status line from remote server 127.0.0.1:9980				Apache-Fehler
2017-02-05 10:43:39	Error	5.10.188.170		AH00898: Error reading from remote server returned by /hosting/discovery

Has the docker image even started? What does “docker ps” print out?

here some new logs:

GET /lool/https%3A%2F%2Fcloud.larsmueller.net%2Findex.php%2Fapps%2Frichdocuments%2Fwopi%2Ffiles%2F3_oc5ly9kwuaz5%3Faccess_token%3Dp8mzBvnb2tcGHg1nbGz0MEBXREneCJkg%26access_token_ttl%3D0%26permission%3Dedit/ws HTTP/1.1

and docker logs give me this:

   wsd-00026-0028 17:14:46.807698 [ client_req_hdl ] WRN  WOPI host did not pass optional access_token_ttl| wsd/FileServer.cpp:255
wsd-00026-0027 17:14:47.653954 [ client_ws_0003 ] ERR  Error in client request handler: No acceptable WOPI hosts found matching the target host [cloud.larsmueller.net] in config.| wsd/LOOLWSD.cpp:1031

edit: problem solved! Collabora works again

So how did you solve this?

Could you please share? Thank you!

I change the URL at the docker image to the cloud domain ,not the office domain. Then it works.

Like this

docker run -t -d -p 127.0.0.1:9980:9980 -e 'domain=cloud\\.nextcloud\\.com' --restart always --cap-add MKNOD collabora/code

But at the nextcloud Backend enter the https://office.domain.tld

Hello!

I have the same error with “Permission Denied”.

I’ve use this manual https://www.linuxbabe.com/cloud-storage/integrate-collabora-online-server-nextcloud-ubuntu-16-04 step by step.

but the problem appear.
Can someone help me?

sudo docker ps

CONTAINER ID        IMAGE               COMMAND                  CREATED             STATUS                         PORTS                      NAMES
ff2abe37bdc7        collabora/code      "/bin/sh -c 'bash sta"   6 minutes ago       Restarting (1) 2 minutes ago   127.0.0.1:9980->9980/tcp   cocky_dubinsky

sudo docker run -t -d -p 127.0.0.1:9980:9980 -e ‘domain=nextcloud\.corpdomain\.com’ --restart always --cap-add MKNOD collabora/code

Config URL at nextcloud backend
https://office.nextcloud.corpdomain.com

Config of /etc/apache2/sites-enabled/office.corpdomain.com-le-ssl.conf edited based on https://www.collaboraoffice.com/community-en/code-2-0-updates-2/

ServerName office.corpdomain.com

SSLCertificateFile /etc/letsencrypt/live/office.your-domain.com/fullchain.pem
SSLCertificateKeyFile /etc/letsencrypt/live/office.your-domain.com/privkey.pem
Include /etc/letsencrypt/options-ssl-apache.conf

Encoded slashes need to be allowed

AllowEncodedSlashes NoDecode

Container uses a unique non-signed certificate

SSLProxyEngine On
SSLProxyVerify None
SSLProxyCheckPeerCN Off
SSLProxyCheckPeerName Off

keep the host

ProxyPreserveHost On

static html, js, images, etc. served from loolwsd

loleaflet is the client part of LibreOffice Online

ProxyPass /loleaflet https://127.0.0.1:9980/loleaflet retry=0
ProxyPassReverse /loleaflet https://127.0.0.1:9980/loleaflet

WOPI discovery URL

ProxyPass /hosting/discovery https://127.0.0.1:9980/hosting/discovery retry=0
ProxyPassReverse /hosting/discovery https://127.0.0.1:9980/hosting/discovery

Main websocket

ProxyPassMatch “/lool/(.*)/ws$” wss://127.0.0.1:9980/lool/$1/ws nocanon

Admin Console websocket

ProxyPass /lool/adminws wss://127.0.0.1:9980/lool/adminws

Download as, Fullscreen presentation and Image upload operations

ProxyPass /lool https://127.0.0.1:9980/lool
ProxyPassReverse /lool https://127.0.0.1:9980/lool

Where is my problem?

UPD

Apache log

[Fri Feb 10 14:40:22.409045 2017] [proxy_http:error] [pid 3732] (103)Software caused connection abort: [client 127.0.0.1:35184] AH01102: error reading status line from remote server 127.0.0.1:9980
[Fri Feb 10 14:40:22.409255 2017] [proxy:error] [pid 3732] [client 127.0.0.1:35184] AH00898: Error reading from remote server returned by /hosting/discovery

office.nextcloud.corpdomain.com:443 127.0.0.1 - - [10/Feb/2017:14:40:22 +0100] “GET /hosting/discovery HTTP/1.1” 502 3749 “-” “ownCloud Server Crawler”

The problem with my proxy? With docker or proxy Apache conf ?

curl https://office.nextcloud.corpdomain.com/lool

502 Proxy Error

Proxy Error

The proxy server received an invalid response from an upstream server.
The proxy server could not handle the request GET /lool.

Reason: Error reading from remote server


Apache/2.4.18 (Ubuntu) Server at office.corpdomain.com Port 443

So, problem with Apache proxy config or Docker ?