
It’s been 12 years since I’ve locally installed Nextcloud, or rather Owncloud at the time, to become independent of public file storage, calendar and address book synchronization services. At the time, I used a Raspberry Pi 1. Ever since, I have updated and extended my initial installation, moved to more powerful hardware, made it redundant and pushed parts out to a rented bare metal server in a data center. Nevertheless, I pretty much still run it like I did back then: A custom tailored and maintained Apache web server, PHP and Nextcloud installation. That’s all nice and well, but I’m not really keen anymore to keep upgrading to the latest Apache and PHP versions by hand and modifying configuration settings whenever the operating system version changes. Also, time has moved on and things are much more ‘containerized’ compared to back then. And finally, I still use the file based SQLite database as the backend, which might at some point become too small and inflexible for my needs. So over a long ‘nerdy’ weekend, I’ve had a look at a somewhat more modern way to set-up a Nextcloud and then started to experiment.
It turned out that there are a number of options to set-up a new Nextcloud instance with limited effort, and the one most appealing to me was Nextcloud ‘All-In-One’, or Nextcloud AIO for short. It’s containerized and installation on a clean virtual machine with the latest Ubuntu version installed is straight forward: One shell command to download and run a script to install docker, and another shell command to download and start the Nextcloud ‘master’ image/container:
curl -fsSL https://get.docker.com | sudo sh
sudo docker run \
--sig-proxy=false \
--name nextcloud-aio-mastercontainer \
--restart always \
--publish 80:80 \
--publish 8080:8080 \
--publish 8443:8443 \
--volume nextcloud_aio_mastercontainer:/mnt/docker-aio-config \
--volume /var/run/docker.sock:/var/run/docker.sock:ro \
ghcr.io/nextcloud-releases/all-in-one:latest
The only other thing required is to map the public IP address to a domain name. If you go for it without looking left or right, your Nextcloud instance is up and running in about 5 minutes. And this includes pretty much all things, including Nextcloud Talk and Collabora Online Office. As I prefer OnlyOffice with Nextcloud, I deselected the default online office option and installed the OnlyOffice plugin after installation was complete. As an OnlyOffice instance can work with several Nextcloud servers, I only had to copy and paste the link and access secret from my other Nextcloud server and had this part up and running without much fuss as well.
So far, so good, getting started is straight forward! Also, snapshots of the underlying virtual machines make it super easy to go back to a clean VM or to any sane state and experiment with different options and configuration parameters inside and outside of the Nextcloud docker containers. And this I did. Extensively. Over 4 days! I particularly wanted to see how the backup and restore process would work locally and over the network, as redundancy and quick recovery in case of hardware failure or other issues is important to me. As the title of the post suggests, this post will not be the only one on the topic and more posts with details will follow.