Installation Guide: Collabora Office in Nextcloud

System Environments


Collabora Online


Libre Office is an open-source document editing office that can replace Microsoft Word, PowerPoint, and Excel.
Collabora Online is an online version of Libre Office, a cloud-based online office that supports real-time synchronization like Google Docs.

Online offices are very convenient when collaborating on a document with multiple people because everything is synchronized in real-time every time you type a letter.
Since everything is synchronized with the server in real time, it is automatically saved without having to press a separate save button.
So, even if you accidentally close the window or turn off the computer during work, the data is safely stored on the server.

Collabora Online, with these advantages, can replace Google Docs by integrating with Nextcloud.
It is completely free, and Nextcloud allows you to open and edit document files directly on the web browser.
Compatibility is also excellent because documents can be opened on mobile and PC by a web browser.

Installation


First, install the Nextcloud Office app from the Nextcloud app store.

Collabora Nextcloud Office App

This app allows Collabora Online and Nextcloud to connect.
Therefore, you must install separate software that will process documents.
There are two installation methods below.

If you are using the Nextcloud official docker image or installed natively, please click here.

When using a Linuxserver docker image, the Built-in CODE app does not install properly, so Collabora Online must be installed and connected separately using Docker.
If you are using a Linuxserver image, click here.

For Nextcloud Official Docker Image

Collabora Built-in Server App

Simple.
Install Collabora Online – Built-in CODE Server from the Nextcloud App Store.

After installation, go directly to Nextcloud Office Configuration.

For Linuxserver Docker Image

Create a Docker Container


In Portainer, click ‘Add container’ and configure it as follows.

Collabora Portainer 1

The network port is mapped to 9980:9980.

For environment variables, paste the script below.
You can easily paste the script by clicking Advanced mode.

Collabora Portainer 2
aliasgroup2=https://yournextclouddomain
dictionaries=en_US
extra_params=--o:ssl.enable=true
password=foradminconsole
username=foradminconsole

‘dictionaries’ are dictionary language settings.
This is dictionary data used for spell checking, etc., and the example script is set to English only.
There is no limit to the number of dictionaries, but for performance reasons, it is recommended to set only the minimum number of languages.

The password and username are required to access the Collabora server web admin console, but since there is almost nothing you can do in the console, I don’t use it often.
If you do not set either a password or username, the admin console is automatically disabled.

After setting the environment variables, set the Restart Policy to Always and click ‘Deploy’ to create a container.

Nginx Reverse Proxy Configuration


Since I’m using Nginx Proxy Manager (NPM), I will explain based on this.

Collabora NPM 1 en

Create a new proxy and set it as above.

Collabora NPM 2 en

In Custom locations, enter a single slash in ‘Define location’, then click the gear wheel to copy and paste the following script (Security Headers).
If you are not using Cloudflare DNS, you can delete real_ip_header X-Forwarded-For;

add_header X-Frame-Options "SAMEORIGIN" always;
add_header X-Content-Type-Options "nosniff" always;
add_header 'Referrer-Policy' 'no-referrer';add_header Permissions-Policy "accelerometer=();ambient-light-sensor=(); autoplay=();camera=();encrypted-media=();focus-without-user-activation=(); geolocation=();gyroscope=();magnetometer=();microphone=();midi=();payment=();picture-in-picture=(); speaker=();sync-xhr=();usb=();vr=()";
real_ip_header X-Forwarded-For;
Collabora NPM 3 en

In the SSL tab, select the certificate to use and check all the items at the bottom.

When all proxy settings are complete, click Save.

If the OK string appears when you access the Collabora domain with a web browser, it is operating normally.

Nextcloud Office Configuration


Go to the Nextcloud Office tab in Nextcloud administrator settings.

Collabora Nextcloud 1 en

If you installed the built-in server from the Nextcloud App Store, select the second option, ‘Use the built-in CODE’, and if you installed it with Docker, select the first option, ‘Use your server’.

Enter the Collabora domain you set up earlier in the URL in the format https://~, make sure ‘Disable certificate verification’ is unchecked, and press save.
If the connection is successful, a green check will appear as shown in the screenshot above.

Collabora Nextcloud 2 en

To prevent any unexpected incidents, scroll down and fill in the WOPI request whitelist.
Just write down your server IP.

Usage

I tested the feature that synchronizes editing in real-time.


When you click a document file in Nextcloud or create a new document, it opens in the Collabora Online office.

As shown in the video above, if you share a file as an external link and allow editing, even people who do not have a Nextcloud account can start editing the document right away after entering their nickname.
However, since each accessor takes up about 100MB of memory, a certain amount of memory must be available to accommodate a large number of accessors.

After editing, it is automatically saved without having to press the save button, so, conveniently, you can close the window right away.

Until now, I have not installed Microsoft Word or PowerPoint on my PC and have been working on documents only with Nextcloud Collabora Office.
In my experience so far, I have not felt that it is not compatible with Microsoft Word or PPT.

The downside is that it must always be connected to the network smoothly, but if you are only connected to the network, you can immediately continue editing the file on another device without having to move it or send it by email, which is very convenient.

Leave a Comment