Install Docker Collabora community edition : Docker Hub
Launch it with this command line : docker run -t -d -p 127.0.0.1:9980:9980 -e “domain=cloud\.com” -e “server_name=office\.cloud\.com” --restart always --cap-add MKNOD collabora/code
Don’t forget the server_name parameter !
Activate mods on Apache2 : sslproxy_httpproxy_wstunnelproxy
Acquire a Let’sEncrypt certificate for this subdomain.
Create and activate the Vhost :
<VirtualHost *:80>
ServerName office.cloud.com
Redirect permanent / https://office.cloud.com/
</VirtualHost>
<VirtualHost *:443>
ServerName office.cloud.com
ServerAdmin admin@cloud.com
DocumentRoot /var/www/certbot
SSLEngine on
SSLCipherSuite EECDH+AESGCM:EDH+AESGCM:AES256+EECDH:AES256+EDH
SSLProtocol All -SSLv2 -SSLv3 -TLSv1 -TLSv1.1
SSLHonorCipherOrder On
SSLCertificateFile /etc/letsencrypt/live/office.cloud.com/fullchain.pem
SSLCertificateKeyFile /etc/letsencrypt/live/office.cloud.com/privkey.pem
# 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 coolwsd
# browser is the client part of Collabora Online
ProxyPass /browser https://127.0.0.1:9980/browser retry=0
ProxyPassReverse /browser https://127.0.0.1:9980/browser
# 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
# Capabilities
ProxyPass /hosting/capabilities https://127.0.0.1:9980/hosting/capabilities retry=0
ProxyPassReverse /hosting/capabilities https://127.0.0.1:9980/hosting/capabilities
# Main websocket
ProxyPassMatch "/cool/(.*)/ws$" wss://127.0.0.1:9980/cool/$1/ws nocanon
# Admin Console websocket
ProxyPass /cool/adminws wss://127.0.0.1:9980/cool/adminws
# Download as, Fullscreen presentation and Image upload operations
ProxyPass /cool https://127.0.0.1:9980/cool
ProxyPassReverse /cool https://127.0.0.1:9980/cool
# Compatibility with integrations that use the /lool/convert-to endpoint
ProxyPass /lool https://127.0.0.1:9980/cool
ProxyPassReverse /lool https://127.0.0.1:9980/cool
</VirtualHost>