How to Install Nextcloud 13.0.5 on Fedora 28

Welcome to Fedora Tutorial. Today, we are going to install Nextcloud on Fedora 28. Nextcloud is a powerful, rich features personal cloud appliance. You can use Nextcloud as an online file sharing and storage service. The new Nextcloud 13.0.5 server is now available for download. It comes with many new features, better performance and many bug fixes. To install Nextcloud on Fedora 28, there are several things we need to prepare. Let’s jump into it. 

In my previous tutorial, I have written some tutorial to install Nextcloud server on various operating systems. Please check out from the link below:

Table of Contents

  1. Install LAMP Server on Fedora 27
  2. Install additional PHP modules
  3. Download Nextcloud
  4. Configure Apache-Nextcloud
  5. Create a MySQL database
  6. Configure SELinux 
  7. Finalizing the Nextcloud installation

Steps to Install Nextcloud 13 on Fedora 28

Step 1. Install LAMP Server on Fedora 28

We are going to run Nextcloud on top of LAMP Server. LAMP (Linux, Apache, MySQL/MariaDB and PHP) is a powerful appliance that will turn your Linux into a powerful web server. Please read this post to install LAMP Server on Fedora 28.

Step 2. Install additional php modules

Nextcloud requires some php modules to be installed. After setting up LAMP Server, continue installing some php modules with the following command.

su
dnf install php-zip php-pdo_mysql php-imagic php-ctype php-dom php-gd php-zlib

Step 3. Download Nextcloud

Download the latest package of Nextcloud. By the time we write this article, Nextcloud 13.0.5 is available on the official website. So, let’s download this one.

cd /tmp
wget https://download.nextcloud.com/server/releases/nextcloud-13.0.5.zip

Extract the file

unzip nextcloud-13.0.5.zip

Change ownership to Apache user

chown -R apache:apache nextcloud

Move the nextcloud directory to /var/www/html

mv nextcloud /var/www/html

Step 4. Configure Apache (Create new Virtual Host)

After we move the nextcloud directory to the web server root folder, we need to create a new virtual host for Nextcloud. 

nano /etc/httpd/conf.d/nextcloud.conf

Now paste the following lines

Alias /nextcloud "/var/www/html/nextcloud/"

<Directory /var/www/html/nextcloud/>
Options +FollowSymlinks
AllowOverride All

<IfModule mod_dav.c>
Dav off
</IfModule>

SetEnv HOME /var/www/html/nextcloud
SetEnv HTTP_HOME /var/www/html/nextcloud

</Directory>

Please note that you will need to modify the lines above if you install nextcloud to a different location. Close and save the file.

5. Create a new MySQL Database and User

The following step will create a new user and database for our Nextcloud.

Login to MySQL console

mysql -u root -p

Create New user:

CREATE USER 'dhani'@'localhost' IDENTIFIED BY '12345';

Create new Nextcloud database

CREATE DATABASE nextcloud;

Grant permission

GRANT ALL PRIVILEGES ON nextcloud.* TO 'dhani'@'localhost' IDENTIFIED BY '12345';
FLUSH PRIVILEGES;
EXIT;

6. Configure SELinux

We need to set SELinux to permissive. By default, the SELinux policy is set to enforcing.

nano /etc/selinux/config

Set the SELINUX to permissive as shown in the following image.

Now reboot Fedora

reboot

Step 7. Configure Nextcloud via Web Browser

Open a web browser and then type the Fedora IP address. 

http://192.168.100.10/nextcloud

Don’t forget to change the IP address with your Fedora IP address. We will need to create an admin account that responsible to the Nextcloud server.

Create a new admin user and password. 

Select MySQL/MariaDB and then enter the MySQL database and user we created earlier. Click Finish setup. In few moments, Nextcloud is ready.

install nextcloud on fedora 28

Thanks for reading this How to Install Nextcloud on Fedora 28. Please share this article if you think its useful. See you in the next Fedora tutorials. 

6 Comments

  1. Thanks for the Tutorial but I’m getting this error: “Internal Server Error

    The server encountered an internal error and was unable to complete your request.
    Please contact the server administrator if this error reappears multiple times, please include the technical details below in your report.
    More details can be found in the webserver log.”

    Can you please help me

  2. Hello thanks for this Tuto

    I have the same error

    “Internal Server Error

    The server encountered an internal error and was unable to complete your request.

    Please contact the server administrator if this error reappears multiple times, please include the technical details below in your report.

    More details can be found in the webserver log.”

    I have restart httpd

    Thank for your help

  3. thank you for sharing this most helpful post. after some trial and error i figured out 2 things:

    php-imagic should be php-imagick

    also after doing all said procedures i too had the internal server error but doing a dnf install nextcloud before rebooting fixed the issue and is now running flawlessly!

    i’m not sure if it’s the flavor of linux (Fedora Server 28) or perhaps i missed something along the way but it was the fix for me!

1 Trackback / Pingback

  1. How to Backup Linux to Remote WebDAV using Deja Dup

Leave a Reply