Hi, after a lot of work I did actually get it up and going. I now have two NextCloud servers with Collabora working on them. One is for my business second is my personal NextCloud for our family.
Collabora uses a LOT of memory. I had Mail In A Box on Digital Ocean second smallest server. It was plenty for Mail In A Box but not enough for Collabora.
I have Mail In A Box on a separate server (droplet) the second smallest $10.00 a month plan).
I have Collabora on a separate server on the same plan ($10.00) It works great. The Collabora server can handle multiple NextCloud accounts if you have the power. I did have my business and personal connections to the same server. My business uses it 99.9% of the time. I just removed the connection from my personal. I always use OpenOffice on my MacBook so I don’t ever use Collabora for personal use. Buy, my employees and my business laptop are ChromBooks and definitely needs Collabora.
I can be long winded…lol So here is how I did it
-
Install Mail In A Box on a server (droplet) (I have had mine on Amazon AWS, Google Cloud, Digital Ocean, and Cloud At Cost). I HIGHLY don’t recommend Cloud At Cost. They shut the entire company down for days last week with no word if and when our servers would ever come back up. I also don’t recommend Google Cloud as you have to do some custom configurations in PostFix to send emails as Google Cloud blocks SMTP ports. Amazon AWS works great but is more expensive than Digital Ocean. (You may already know this but I figure add this in for any future readers that don’t). I do love Digital Ocean!
-
After installing Mail In The Box you have to spin up a separate server. I tried the cheapest $5.00 month plan but it just doesn’t have enough power to run Collabora. The $10.00 plan is Eh. It’s fine if you’re the only one using it. If you have multiple people using it AT THE SAME TIME then you will need more power. Only install NGINX and docker. I used Ubuntu 16.04 and locked it down on port 443 with UFW by the internal IP for security. Here is how I did it. Just change the sample domains to yours
sudo apt update
sudo apt install docker.io
sudo docker pull collabora/code
sudo docker run -t -d -p 127.0.0.1:9980:9980 -e ‘domain=nextcloud\.your-domain\.com’ --restart always --cap-add MKNOD collabora/code
sudo apt install nginx
sudo nano /etc/nginx/sites-available/office.your-domain.com
server {
listen 80;
server_name office.your-domain.com;
root /usr/share/nginx/office;
}
ln -s /etc/nginx/available/office.your_domain.com /etc/nginx/sites-enabled/office.your_domain.com
sudo mkdir /usr/share/nginx/office
sudo chown www-data:www-data /usr/share/nginx/office -R
sudo apt install letsencrypt
sudo letsencrypt certonly --webroot --email your-email-address -d office.your-domain.com -w /usr/share/nginx/office/
REPLACE THE CONFIGURATION WITH THIS
sudo nano /etc/nginx/sites-available/office.your-domain.com.conf
server {
listen 443 ssl;
server_name office.your-domain.com;
root /usr/share/nginx/office;
ssl_protocols TLSv1.1 TLSv1.2;
ssl_certificate /etc/letsencrypt/live/office.your-domain.com/fullchain.pem;
ssl_certificate_key /etc/letsencrypt/live/office.your-domain.com/privkey.pem;
# static files
location ^~ /loleaflet {
proxy_pass https://localhost:9980;
proxy_set_header Host $http_host;
}
# WOPI discovery URL
location ^~ /hosting/discovery {
proxy_pass https://localhost:9980;
proxy_set_header Host $http_host;
}
# websockets, download, presentation and image upload
location ^~ /lool {
proxy_pass https://localhost:9980;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection “upgrade”;
proxy_set_header Host $http_host;
}
}
CHECK NGINX --> sudo nginx -t
RESTART NGINX --> sudo service nginx restart
Now just connect to NextCloud in settings. Don’t add the port. Just the domain name.
Go back in and setup UFW rules for the two servers and you are golden!
If you need any help just let me know.