0

We have an Ubuntu Server 18.04 LTS machine running a Nextcloud instance on Apache via a Vhost. This Nextcloud installation is located at /var/www/nextcloud and only allows connecting via HTTPS on port 443: connections via HTTP on port 80 get automatically redirected thanks to the configuration setup by certbot-auto; hence, ports 80 and 443 are being listened on already by Apache.

We use Nextcloud for file sharing and collaboration. Since I wanted to allow users to edit documents directly (without downloading them, editing and reuploading), I decided to install the ONLYOFFICE Document Server, to integrate it into Nextcloud. Nextcloud only allows ONLYOFFICE integration if the server uses SSL (it prevents you from connecting if you type in an http:// address), so I set it up via Docker, to ease installation and to prevent conflicts between Apache and nginx.

Now, I chose 8080 as port for HTTP and 44380 as port for HTTPS, so I started the container with:

sudo docker run -i -t -d -p 8080:80 -p 44380:443 --restart=always -v /app/onlyoffice/DocumentServer/data:/var/www/onlyoffice/Data  onlyoffice/documentserver

I additionally created symlinks to my existant Let's Encrypt certificate and key, so when I renew them with certbot for Nextcloud, they also get renewed for ONLYOFFICE.

When I try to connect to http://[serveraddress]:8080 (where [serveraddress] is the address of my server), I correctly get shown this:

ONLYOFFICE Configuration Wizard

But when I connect to https://[serveraddress]:44380, my browser says it couldn't connect (check Internet connection, firewall, try to restart router etc.)

How do I diagnose and hopefully fix this issue?

Manchineel
  • 139
  • 2
  • 11

1 Answers1

0

If we understood it right, you want to use ONLYOFFICE Document Server to be able to edit your files from Nextcloud.

Now, I chose 8080 as port for HTTP and 44380 as port for HTTPS, so I started the container with:

docker run -i -t -d -p 8080:80 -p 44380:443 -v /opt/onlyoffice/Data/var/www/onlyoffice/Data onlyoffice/communityserver

First of all we can see that you installed ONLYOFFICE Community Server instead of the Document Server. Please follow this link to find an instruction on how to install Document Server with Docker.

You will also need to generate own SSL certificates for the Document Server to make it work on HTTPS. You can find the instruction in the same article above.

  • Hi! Welcome to SE. Could you please complete the answer with the relevant parts of the linked page? A mere link doesn't serve as an answer here, and precious information could easily be removed or URL may be modified, causing a broken link to take place. – Manchineel Jul 02 '18 at 12:37
  • Also, I already have Certs – Manchineel Jul 02 '18 at 12:40
  • Please specify if you have installed ONLYOFFICE Document Server, as Community Server is another product, which does not have editors included. – Alexander_ONLYOFFICE Jul 03 '18 at 10:38
  • yes. After running sudo docker run -i -t -d -p 44380:443 --resta rt=always -v /app/onlyoffice/DocumentServer/data:/var/www/onlyoffi ce/Data onlyoffice/documentserver – Manchineel Jul 03 '18 at 12:10
  • 1
    I still get the error "Unable to connect" – Manchineel Jul 03 '18 at 12:11
  • For some reason there was an error (a space) in the comment, but in the shell the command pasted correctly – Manchineel Jul 03 '18 at 12:19
  • @alex2003super, could you please send a screenshot of the error - "Unable to connect". – Alexander_ONLYOFFICE Jul 04 '18 at 07:44
  • Hi. Sorry for late response. I have read online that ONLYOFFICE over HTTPS doesn't play well with custom ports. I have now installed ONLYOFFICE natively and I had to move Nextcloud/Apache to an NGINX Reverse Proxy. It's working now, even though I had to modify my setup a bit. – Manchineel Jul 06 '18 at 07:47
  • Hi @alex2003super, we are glad that the issue has been resolved. – Alexander_ONLYOFFICE Jul 10 '18 at 12:26
  • Now unfortunately the Spellchecker is not working, even if l rebuild it (nodehun error) or switch to the older "supported" nodejs version (no error, but it just remains grayed out) – Manchineel Jul 15 '18 at 10:26
  • Hi @alex2003super, please follow this [link](https://github.com/ONLYOFFICE/DocumentServer/issues/312#issuecomment-392479211) to find an instruction on GitHub website about how to fix the spellchecker on Ubuntu 18.04. – Alexander_ONLYOFFICE Jul 16 '18 at 11:08
  • done that already. I Googled my error and that was the first thing I did. I remember getting this to work on a previous install. – Manchineel Jul 16 '18 at 13:40
  • In the end what helped me was to reinstall onlyoffice fully and to replace /usr/local/bin/node with a symlink to /usr/local/bin/nodejs . My install is very awkward (when I use n to update Nodejs its effect is displayed on node -v, when I use nvm to update instead, I get changes on nodejs -v), but hey, it works. Also, TIL OO Spellchecker isn't functional on mobile – Manchineel Jul 16 '18 at 13:44