File Sharing

Host Nextcloud on VeloxaHost

Nextcloud is a self-hosted file sync and sharing platform with desktop and mobile clients, plus apps for calendars, contacts and collaborative editing. Families, small companies and teams with data-residency requirements run it to keep their files on a server they control rather than in Google Drive or Dropbox.

The one-click install sets up Apache, MySQL and PHP on Ubuntu 24.04, unpacks the latest Nextcloud release into /var/www/nextcloud and runs the command-line installer, so the server comes up ready to log in as admin.

Install it yourself

  1. Install Apache, MariaDB and the PHP modules Nextcloud uses.
    apt install -y apache2 mariadb-server libapache2-mod-php php-gd php-mysql php-curl php-mbstring \
      php-intl php-gmp php-bcmath php-xml php-imagick php-zip unzip
    
  2. Create the database and its user. Pick your own password.
    mysql -e "CREATE DATABASE nextcloud CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci; \
      CREATE USER 'nextcloud'@'localhost' IDENTIFIED BY 'DB_PASSWORD'; \
      GRANT ALL ON nextcloud.* TO 'nextcloud'@'localhost'; FLUSH PRIVILEGES;"
    
  3. Download the latest release and give it to the web server user.
    wget https://download.nextcloud.com/server/releases/latest.zip -O /tmp/nextcloud.zip
    unzip -q /tmp/nextcloud.zip -d /var/www/ && chown -R www-data:www-data /var/www/nextcloud
    
  4. Create /etc/apache2/sites-available/nextcloud.conf with DocumentRoot /var/www/nextcloud and a <Directory /var/www/nextcloud> block containing Require all granted and AllowOverride All. Then enable it.
    a2ensite nextcloud.conf && a2dissite 000-default.conf
    a2enmod rewrite headers env dir mime && systemctl restart apache2
    
  5. Run the installer. It prompts for the database and admin passwords.
    sudo -u www-data php /var/www/nextcloud/occ maintenance:install \
      --database mysql --database-name nextcloud --database-user nextcloud --admin-user admin
    
  6. Allow your domain, and switch background jobs to cron.
    sudo -u www-data php /var/www/nextcloud/occ config:system:set trusted_domains 1 --value=cloud.example.com
    sudo -u www-data php /var/www/nextcloud/occ background:cron
    echo '*/5 * * * * php -f /var/www/nextcloud/cron.php' | crontab -u www-data -
    
  7. Point the domain at an address where ports 80 and 443 reach the server (a dedicated IPv4 address, a paid add-on with limited availability; IPv6 is not available in US East yet), then get a certificate with Certbot.
    apt install -y certbot python3-certbot-apache && certbot --apache -d cloud.example.com
    

FAQ

What license is Nextcloud under?

Nextcloud Server is free software under the GNU AGPLv3. You can run it for any purpose without a license fee. Nextcloud GmbH sells an optional enterprise subscription with support.

What is the admin login after a one-click install?

The admin user is admin. VeloxaHost replaces the install script's placeholder password with a random one at deploy time and stores it encrypted; organization owners and admins can reveal it on the server's page, and every reveal is recorded in the audit log. Change it after your first login and then delete the stored copy.

Where are my files stored?

By default in the data folder of the install, /var/www/nextcloud/data, with file metadata, shares and users in the database. Back up both together, for example with a VeloxaHost backup schedule (every 6 or 12 hours, daily or weekly, keeping the last 1 to 10).

How do I upgrade Nextcloud?

Use the built-in updater, from the admin settings or on the command line with sudo -u www-data php /var/www/nextcloud/updater/updater.phar. Nextcloud cannot skip major versions, so upgrade one major release at a time. Take a snapshot first so you can roll back.

Will Nextcloud get slow as my team grows?

Nextcloud is a PHP application, so memory and CPU set how many people can sync at once. On a VeloxaHost container you can raise CPU and memory from the console while it runs, and the change applies immediately.

Which VeloxaHost size fits Nextcloud?

The recommended 2 vCPU, 4 GB of RAM and 80 GB of disk is a Veloxa 2, at $20 a month, billed at $0.03 an hour and capped at the monthly price. Size the disk for the files you plan to store. Nextcloud's minimum of 2 vCPU, 2 GB and 20 GB also fits inside the free trial's allowance.