The free cloud storage software ownCloud has blossomed over the past years into a serious competitor for commercial services like Dropbox and Google Drive. Users can now take responsibility for storing their own data, with convenient synchronization between computers and mobile devices by running a small server outfitted with an ownCloud package. NAS device users can also find easy to install ownCloud packages in the package sources for their system.
However, the ownCloud success story suffered a serious setback at the end of April last year. The ownCloud founder Frank Karlitschek [1] and a number of the original developers all left the project in order to pursue development of a fork which they call Nextcloud [2]. Jos Poortvliet who was previously the Community Manager for ownCloud now handles public relations for Nextcloud. He refers to the undertaking as a "re-start". According to Karlitschek and Poortvliet, this re-start was prompted by dissatisfaction arising out of structural problems and various business decisions in the ownCloud organization.
The current version of Nextcloud at the moment of writing, 11.0.1, has a number of new features such as a dedicated apps store, but shares much of its code with Owncloud 9. A write only function is one example of the improvements that have already been built into the fork. This lets anonymous users upload data into your cloud even though they themselves do not have access to files and directories. There's also a new logging function that captures events such as a file release, update or login. In addition, the developers report that they have hardened the software to fend off attacks, and fixed various bugs.
Separation
As a company, Nextcloud is currently at work with Spreed.me [3]. Spreed.me sells a line of computers named Spreedbox [4]. Each Spreedbox comes with a pre-installed video conferencing solution, created by combining a WebRTC server with ownCloud. Frank Karlitschek and Niels Mache head up the Nextcloud organization itself. Prior to joining Nextcloud, Niels Mache was responsible for Spreed.me and is also a co-founder of Red Hat Germany.
The goal of the new project is to significantly expand the web application beyond its core functionality, such as by integrating the WebRTC server from Spreed and its bundled applications.
The project also aims to maintain and officially support frequently used ownCloud applications such as the calendar and contacts administration. NextCloud have also cooperated with Collabora to bring a self-hosted LibreOffice suite into the NextCloud server.
For this Article, we tested Nextcloud on Raspbian Jessie, with Apache and MariaDB (a fork of MySQL). You can access your home server over the internet through setting up port forwarding on your router. You can also use a free SSL certificate from Let's Encrypt to protects your data as it travels over the Internet.
Figure 1: In order to set up encrypted access to Nextcloud, forward ports 80 and 443 from your router to your cloud server (your Pi).
Installation
Before beginning installation of Nextcloud, install all software dependencies and updates for your distribution (Listing 1). Next, install the Apache web server and MariaDB plus all required Apache and PHP extensions (Line 3). After doing this activate the Apache module mod_rewrite for readable URLs and mod_headers for your SSL connection. Next start the web server (lines 4 to 5) and allow it to load. In theory SQLite is sufficient for small amounts of data but MySQL/Maria DB is best for larger installations with multiple users.
$ sudo apt update
$ sudo apt full-upgrade
$ sudo apt install apache2 marphp5-gd php5-json php5-mysql php5-curl php5-intl php5-mcrypt php5-imagick
$ sudo a2enmod rewrite
$ sudo a2enmod headers
$ sudo service apache2 restart
When you install the MariaDB server, the system will request a root password for the database. For security reasons make sure the root password is different from the actual system administrator password, such as the pi user on a Raspberry Pi. Nextcloud now needs a database to store data in the cloud. In order to create the database first log in to the MariaDB server. From there you can set up the database plus all of the corresponding rights and settings (Listing 2). When designating the database user (CREATE USER?
, make sure to select a password that is more secure than secret
– D'oh! Remember the password you choose as you will need it later.
$ mysql -u root -p
MariaDB [(none)]> CREATE DATABASE nextcloud;
MariaDB [(none)]> CREATE USER 'nextcloud'@'localhost' IDENTIFIED BY '<secret>';
MariaDB [(none)]> GRANT ALL PRIVILEGES ON nextcloud.* TO 'nextcloud'@'localhost';
MariaDB [(none)]> FLUSH PRIVILEGES;
MariaDB [(none)]> exit;