This guide describes installing ONLYOFFICE Docs (Community Edition) on Ubuntu and configuring the Yetishare File Previewer plugin so Nova can edit office files inline.
Version note: Yetishare’s development Docker stack uses Document Server 8.2.2.1 (onlyoffice/documentserver:8.2.2.1). For similar behaviour, install a 8.2.x package or container when possible.
Separate server: ONLYOFFICE Document Server can run on a dedicated machine or VM while Yetishare stays on another host. Enter the public Document Server URL for browsers; use Internal Document Server URL and Site URL For Document Server when PHP or Document Server must use different hostnames, HTTPS, or private network paths than end users.
Before you start
- ONLYOFFICE runs as a separate server; it is not bundled inside Yetishare.
- Community Edition is AGPLv3 and may limit simultaneous editors; check ONLYOFFICE’s licence terms.
- Production: use HTTPS for both your site and Document Server.
- JWT must be enabled on Document Server and the secret must match Yetishare (see below).
Install Document Server on Ubuntu
The commands below are taken from ONLYOFFICE’s guide for Debian/Ubuntu (Community = package onlyoffice-documentserver). ONLYOFFICE may update steps over time; if something fails, use their current page as the source of truth:
Version note: Yetishare’s dev Docker image uses Document Server 8.2.2.1. To match that line, install an 8.2.x package if available (see Optional: pin a version below).
1. Dependencies (PostgreSQL, Redis, RabbitMQ, NGINX)
ONLYOFFICE Docs expects PostgreSQL, Redis, RabbitMQ, and NGINX. Install PostgreSQL from Ubuntu, then create the database user and database (the DB user name must be onlyoffice; choose your own password and use it when the installer asks):
sudo apt-get update sudo apt-get install -y postgresql redis-server rabbitmq-server nginx sudo -i -u postgres psql -c "CREATE USER onlyoffice WITH PASSWORD 'onlyoffice';" sudo -i -u postgres psql -c "CREATE DATABASE onlyoffice OWNER onlyoffice;"
On Ubuntu 18.04, install nginx-extrasinstead ofnginx in the line above (ONLYOFFICE’s guide).
2. JWT for Yetishare (set before apt-get install onlyoffice-documentserver)
Yetishare needs JWT enabled and the same secret in admin. You can preset this with debconf-set-selections so it applies at install time (from ONLYOFFICE’s “additional options” documentation). Replace YOUR_LONG_RANDOM_SECRET with a strong value and reuse it in Yetishare JWT Secret:
echo onlyoffice-documentserver onlyoffice/jwt-enabled boolean true | sudo debconf-set-selections echo onlyoffice-documentserver onlyoffice/jwt-secret password YOUR_LONG_RANDOM_SECRET | sudo debconf-set-selections
If Document Server is already installed, enable JWT and set the secret in /etc/onlyoffice/documentserver/local.json (ONLYOFFICE documents this file) and restart Document Server.
3. ONLYOFFICE apt repository and GPG key
mkdir -p -m 700 ~/.gnupg curl -fsSL https://download.onlyoffice.com/GPG-KEY-ONLYOFFICE | gpg --no-default-keyring --keyring gnupg-ring:/tmp/onlyoffice.gpg --import chmod 644 /tmp/onlyoffice.gpg sudo chown root:root /tmp/onlyoffice.gpg sudo mv /tmp/onlyoffice.gpg /usr/share/keyrings/onlyoffice.gpg echo "deb [signed-by=/usr/share/keyrings/onlyoffice.gpg] https://download.onlyoffice.com/repo/debian squeeze main" | sudo tee /etc/apt/sources.list.d/onlyoffice.list sudo apt-get update
The repository uses the squeeze suite name but is intended for current Debian and Ubuntu; ONLYOFFICE states it is compatible with Ubuntu derivatives.
4. Microsoft TrueType fonts and Document Server package
sudo apt-get install -y ttf-mscorefonts-installer sudo apt-get install -y onlyoffice-documentserver
During installation, enter the PostgreSQL password for the onlyoffice user when prompted (the one you used in CREATE USER above if you kept the example). Accept font and EULA prompts if shown.
By default Document Server listens on port 80 (ONLYOFFICE documents changing the port via debconf-set-selections and onlyoffice/ds-port if needed).
Optional: install a specific version (e.g. 8.2.x)
List available packages, then install a version close to your target (paste the exact candidate version Apt shows):
apt-cache policy onlyoffice-documentserver sudo apt-get install onlyoffice-documentserver=VERSION_FROM_POLICY
ONLYOFFICE’s repository must still publish that version.
5. Verify
Open http://localhost (or your server hostname) in a browser to reach the ONLYOFFICE welcome page. From another machine use http://SERVER_IP or your TLS URL after you configure HTTPS.
curl -fsS -o /dev/null -w "%{http_code}" http://127.0.0.1/healthcheck
You should see a 2xx HTTP code when Document Server is healthy.
Private networks
If Document Server must fetch your Yetishare URLs using a private IP or internal hostname, ONLYOFFICE may block that until you allow private addresses (Docker dev uses ALLOW_PRIVATE_IP_ADDRESS=true). Configure the equivalent for a native Linux install per ONLYOFFICE’s docs for your version.
TLS
Terminate TLS with a reverse proxy (Nginx/Apache) or ONLYOFFICE’s documented TLS setup so browsers load Document Server over https://.
Configure Yetishare
In the admin area go to:
Admin → Plugins → File Previewer → Plugin Settings → Documents
URL shape: /admin/plugin/filepreviewer/settings (Documents section).
| Setting | What to enter | Where the value comes from |
|---|---|---|
| Enable Document Editing | Yes | Turn on after Document Server is reachable with JWT configured. |
| Document Server URL | Base URL only (no path), e.g. https://office.example.com | The origin users’ browsers use to load the editor. Use https:// when your site uses HTTPS. |
| JWT Secret | Same string as on Document Server | Must match JWT_SECRET (or equivalent) in Document Server config. |
| Editable File Types | Comma-separated extensions | Default: docx,xlsx,pptx,odt,ods,odp. Change only if you want to restrict types. |
| Internal Document Server URL | Optional base URL | Use when PHP / the web server should reach ONLYOFFICE on a different URL than end users (e.g. public https://office.example.com in the browser, but http://127.0.0.1:8080 from the app). Leave empty to use Document Server URL for server-side calls. |
| Site URL For Document Server | Optional Yetishare base URL | How Document Server reaches your site to download files and post save callbacks. Leave empty to use your site’s configured web root. Set when ONLYOFFICE cannot use the public URL (split DNS, Docker, internal hostname). |
| Allow New Office Documents | Yes or No | If Yes, Nova can offer new .docx, .xlsx, .pptx where supported. |
Server Status: With editing enabled, the Documents tab runs a health check against Document Server (/healthcheck). Use it to confirm connectivity after saving.
How to discover URLs
- Document Server URL: The same origin you open in a browser to confirm ONLYOFFICE is running (scheme + host + port).
- JWT Secret: The value you set in Document Server JWT configuration (copy into Yetishare exactly).
- Internal Document Server URL: From the Yetishare server, test reachability, e.g.
curl -I https://office.example.com/healthcheckusing the address PHP should use. - Site URL For Document Server: From the Document Server host, use the base URL that successfully reaches Yetishare (for file fetch and callbacks).
References
- ONLYOFFICE Help Center - install on Ubuntu
- ONLYOFFICE Guides - same installation topic
- Yetishare
docs/file-editing.md(office / ONLYOFFICE section) and Docker notes underdocker/README.md(optional dev compose).