{"id":44,"date":"2020-05-11T17:27:46","date_gmt":"2020-05-11T15:27:46","guid":{"rendered":"http:\/\/reglisss.freeboxos.fr\/wordpress\/?page_id=44"},"modified":"2020-05-12T00:46:55","modified_gmt":"2020-05-11T22:46:55","slug":"installation-de-nextcloud-sous-ubuntu-20","status":"publish","type":"page","link":"https:\/\/reglisss.freeboxos.fr\/wordpress\/installation-de-nextcloud-sous-ubuntu-20\/","title":{"rendered":"INSTALLATION DE NEXTCLOUD SOUS UBUNTU 20"},"content":{"rendered":"\n<p>sudo apt update &amp;&amp; sudo apt full-upgrade &amp;&amp; sudo apt autoremove<br>sudo apt install apache2 php libapache2-mod-php mariadb-server php-mysql<br>sudo apt install php-curl php-gd php-intl php-json php-mbstring php-xml php-zip<\/p>\n\n\n\n<p>puis <a rel=\"noreferrer noopener\" target=\"_blank\" href=\"https:\/\/www.tecmint.com\/install-nextcloud-in-ubuntu\/\">https:\/\/www.tecmint.com\/install-nextcloud-in-ubuntu\/<\/a><\/p>\n\n\n\n<p><br>sudo nano \/var\/www\/html\/nextcloud\/config\/config.php<br>pour rajouter<br>array (<br>0 => &lsquo;192.168.43.112&rsquo;,<br>1 => &lsquo;reglisss.freeboxos.fr&rsquo;,<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Step 1: Installing LAMP on Ubuntu<\/h3>\n\n\n\n<p><strong>1.<\/strong>&nbsp;To install a&nbsp;<strong>LAMP<\/strong>&nbsp;stack, open a terminal window and connect to your&nbsp;<strong>Ubuntu<\/strong>&nbsp;server via&nbsp;<strong>SSH<\/strong>. Then run the following command to install&nbsp;<strong>Apache<\/strong>,&nbsp;<strong>MariaDB<\/strong>&nbsp;server and&nbsp;<strong>PHP<\/strong>&nbsp;packages, plus the required and recommended PHP modules.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">$ sudo apt-get update\n$ sudo apt-get install apache2 mariadb-server libapache2-mod-php7.2 php7.2-gd php7.2-json php7.2-mysql php7.2-curl php7.2-mbstring php7.2-intl php-imagick php7.2-xml php7.2-zip\n<\/pre>\n\n\n\n<p><strong>2.<\/strong>&nbsp;Once the installation of the packages is complete, the installer will setup the&nbsp;<strong>Apache2<\/strong>&nbsp;and&nbsp;<strong>MariaDB<\/strong>&nbsp;services to start for now and enable them to automatically start at system boot.<\/p>\n\n\n\n<p>To check if the two services are started and enabled, run the following&nbsp;<strong>systemctl<\/strong>&nbsp;commands.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">$ systemctl status apache2\n$ systemctl status mariadb\n$ systemctl is-enabled apache2\n$ systemctl is-enabled mariadb\n<\/pre>\n\n\n\n<p><strong>Note<\/strong>: If for one reason or the other the above services are not started and enabled, start and enable them as shown.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">$ sudo systemctl start apache2\n$ sudo systemctl start mariadb\n$ sudo systemctl enable apache2\n$ sudo systemctl enable mariadb\n<\/pre>\n\n\n\n<p><strong>3.<\/strong>&nbsp;Next, secure the&nbsp;<strong>MariaDB<\/strong>&nbsp;server installation by running the security script that ships with the package as shown.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">$ sudo mysql_secure_installation\n<\/pre>\n\n\n\n<p>Then answer the following questions when prompted (remember to set a strong and secure root password):<\/p>\n\n\n\n<ul class=\"wp-block-list\"><li>Enter current password for root (enter for none):&nbsp;<code>enter<\/code><\/li><li>Set root password? [Y\/n]&nbsp;<code>y<\/code><\/li><li>Remove anonymous users? [Y\/n]&nbsp;<code>y<\/code><\/li><li>Disallow root login remotely? [Y\/n]&nbsp;<code>y<\/code><\/li><li>Remove test database and access to it? [Y\/n]&nbsp;<code>y<\/code><\/li><li>Reload privilege tables now? [Y\/n]&nbsp;<code>y<\/code><\/li><\/ul>\n\n\n\n<figure class=\"wp-block-image\"><img decoding=\"async\" src=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2020\/01\/secure-mysql-server-installation.png\" alt=\"Secure MySQL Server Installation\"\/><\/figure>\n\n\n\n<p><a href=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2020\/01\/secure-mysql-server-installation.png\"><\/a><\/p>\n\n\n\n<p>Secure MySQL Server Installation<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Step 2: Install Nextcloud in Ubuntu<\/h3>\n\n\n\n<p><strong>4.<\/strong>&nbsp;After securing the database installation, you need to create a database and database user for&nbsp;<strong>Nextcloud<\/strong>. So, log into the&nbsp;<strong>MariaDB<\/strong>&nbsp;server to access the&nbsp;<strong>MySQL<\/strong>&nbsp;shell.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">$ sudo mysql -u root -p \n<\/pre>\n\n\n\n<p>And run the following&nbsp;<strong>sql<\/strong>&nbsp;commands (replace \u201c<strong>=@!#@%$lab<\/strong>\u201d with your secure password).<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"><strong>MariaDB [(none)]&gt;<\/strong> CREATE DATABASE nextcloud; \n<strong>MariaDB [(none)]&gt;<\/strong> CREATE USER ncadmin@localhost IDENTIFIED BY '<strong>=@!#@%$lab<\/strong>'; \n<strong>MariaDB [(none)]&gt;<\/strong> GRANT ALL PRIVILEGES ON nextcloud.*  TO ncadmin@localhost IDENTIFIED BY '<strong>=@!#@%$lab<\/strong>'; \n<strong>MariaDB [(none)]&gt;<\/strong> FLUSH PRIVILEGES; \n<strong>MariaDB [(none)]&gt;<\/strong> EXIT;\n<\/pre>\n\n\n\n<p><strong>5.<\/strong>&nbsp;Now go to the&nbsp;<a href=\"https:\/\/nextcloud.com\/install\" target=\"_blank\" rel=\"noreferrer noopener\">Nextcloud Download Page<\/a>, then click on&nbsp;<strong>Download Nextcloud<\/strong>&nbsp;Server =&gt;&nbsp;<strong>Download Nextcloud<\/strong>&nbsp;to grab a&nbsp;<code>.zip<\/code>&nbsp;archive or run the following commands to download it from the command-line using&nbsp;<a href=\"https:\/\/www.tecmint.com\/10-wget-command-examples-in-linux\/\" target=\"_blank\" rel=\"noreferrer noopener\">wget command<\/a>.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">$ sudo wget -c https:\/\/download.nextcloud.com\/server\/releases\/nextcloud-18.0.0.zip\n<\/pre>\n\n\n\n<p><strong>6.<\/strong>&nbsp;Next, extract the archive contents and copy the extracted&nbsp;<strong>nextcloud<\/strong>&nbsp;directory\/folder into your web server\u2019s document root. Also set the appropriate ownership on the nextcloud directory, as follows.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">$ sudo unzip nextcloud-18.0.0.zip\n$ sudo cp -r nextcloud \/var\/www\/html\/\n$ sudo chown -R www-data:www-data \/var\/www\/html\/nextcloud\n<\/pre>\n\n\n\n<h3 class=\"wp-block-heading\">Step 3: Configure Apache to Serve Nextcloud<\/h3>\n\n\n\n<p><strong>7.<\/strong>&nbsp;The next step is to create an Apache configuration file for&nbsp;<strong>Nextcloud<\/strong>&nbsp;under the&nbsp;<strong>\/etc\/apache2\/sites-available<\/strong>&nbsp;directory.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">$ sudo nano \/etc\/apache2\/sites-available\/nextcloud.conf\n<\/pre>\n\n\n\n<p>Copy and paste the following lines in the file (replace&nbsp;<strong>\/var\/www\/html\/nextcloud\/<\/strong>&nbsp;if your installation directory is different).<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">Alias \/nextcloud \"\/var\/www\/html\/nextcloud\/\"\n\n&lt;Directory \/var\/www\/html\/nextcloud\/&gt;\n  Require all granted\n  Options FollowSymlinks MultiViews\n  AllowOverride All\n\n &lt;IfModule mod_dav.c&gt;\n  Dav off\n &lt;\/IfModule&gt;\n\n SetEnv HOME \/var\/www\/\/html\/nextcloud\n SetEnv HTTP_HOME \/var\/www\/html\/nextcloud\n&lt;\/Directory&gt;\n<\/pre>\n\n\n\n<p>Then save the file and close it.<\/p>\n\n\n\n<p><strong>8.<\/strong>&nbsp;Next, enable the newly created site and other Apache modules in the Apache configuration structure as shown.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">$ sudo a2ensite nextcloud.conf\n$ sudo a2enmod rewrite\n$ sudo a2enmod headers\n$ sudo a2enmod env\n$ sudo a2enmod dir\n$ sudo a2enmod mime\n<\/pre>\n\n\n\n<figure class=\"wp-block-image\"><img decoding=\"async\" src=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2020\/01\/enable-nextcloud-site-and-other-apache-modules.png\" alt=\"Enable Apache Modules for Nextcloud\"\/><\/figure>\n\n\n\n<p><a href=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2020\/01\/enable-nextcloud-site-and-other-apache-modules.png\"><\/a><\/p>\n\n\n\n<p>Enable Apache Modules for Nextcloud<\/p>\n\n\n\n<p><strong>9.<\/strong>&nbsp;Finally, restart the&nbsp;<strong>Apache2<\/strong>&nbsp;service for the recent changes to take effect.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">$ sudo systemctl restart apache2 \n<\/pre>\n\n\n\n<h3 class=\"wp-block-heading\">Step 4: Complete Nextcloud Installation via Graphical Wizard<\/h3>\n\n\n\n<p><strong>10.<\/strong>&nbsp;Now you need to complete the installation via the graphical installation wizard from a web browser. Open your browser and point it to the following address:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">http:\/\/SERVR_IP\/nextcloud\/\nOR\nhttp:\/\/SERVER_ADDRESS\/nextcloud\/\n<\/pre>\n\n\n\n<p><strong>11.<\/strong>&nbsp;Once the installation wizard loads, create a nextcloud superuser\/admin user account. Enter the username and password. Besides, click on the&nbsp;<strong>Storage and Database<\/strong>&nbsp;link to access additional installation configuration options for your Nextcloud data directory and database.<\/p>\n\n\n\n<p>Then fill in the database connection details as shown in the following screenshot and click&nbsp;<strong>Finish Setup<\/strong>.<a href=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2020\/01\/Nextcloud-Setup.png\"><\/a><\/p>\n\n\n\n<p>Nextcloud Setup Wizard<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img decoding=\"async\" src=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2020\/01\/Nextcloud-Setup.png\" alt=\"Nextcloud Setup Wizard\"\/><\/figure>\n\n\n\n<p><strong>12.<\/strong>&nbsp;When the installation is complete, you will see the following window. Click on the forward arrow that will appear at the right side of the blue window to proceed and follow the prompts.<a href=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2020\/01\/Nextcloud-Installation-Wizard.png\"><\/a><\/p>\n\n\n\n<p>Nextcloud Installation Wizard<\/p>\n\n\n\n<p><strong>13.<\/strong>&nbsp;Then in the next window, click&nbsp;<strong>Finish Setup<\/strong>&nbsp;to start using your new Nextcloud server.<a href=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2020\/01\/start-using-nextcloud.png\"><\/a><\/p>\n\n\n\n<p>Nextcloud Setup Finished<\/p>\n\n\n\n<p><strong>14.<\/strong>&nbsp;The following screenshot shows the Nextcloud web browser client\u2019s main dashboard.<a href=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2020\/01\/nextcloud-default-dashboard.png\"><\/a><\/p>\n\n\n\n<p>Nextcloud Dashboard<\/p>\n\n\n\n<p>For more information and server configurations, see the&nbsp;<a href=\"https:\/\/docs.nextcloud.com\/server\/18\/admin_manual\/contents.html\" target=\"_blank\" rel=\"noreferrer noopener\">Nextcloud admin manual<\/a>&nbsp;and to learn how to use it, read the&nbsp;<a href=\"https:\/\/docs.nextcloud.com\/server\/latest\/user_manual\/\" target=\"_blank\" rel=\"noreferrer noopener\">Nextcloud user manual<\/a>.<\/p>\n\n\n\n<p>That\u2019s all! In this article, we have shown how to set up&nbsp;<strong>Nextcloud<\/strong>&nbsp;server software in the&nbsp;<strong>Ubuntu Linux&nbsp;<\/strong>server, using the&nbsp;<strong>Apache<\/strong>&nbsp;web server and&nbsp;<strong>MariaDB<\/strong>&nbsp;database. If you have any questions concerning this guide or any additions, reach us via the comment form below.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>sudo apt update &amp;&amp; sudo apt full-upgrade &amp;&amp; sudo apt autoremovesudo apt install apache2 php libapache2-mod-php mariadb-server php-mysqlsudo apt install php-curl php-gd php-intl php-json php-mbstring php-xml php-zip puis https:\/\/www.tecmint.com\/install-nextcloud-in-ubuntu\/ sudo nano \/var\/www\/html\/nextcloud\/config\/config.phppour rajouterarray (0 => &lsquo;192.168.43.112&rsquo;,1 => &lsquo;reglisss.freeboxos.fr&rsquo;, Step 1: Installing LAMP on Ubuntu 1.&nbsp;To install a&nbsp;LAMP&nbsp;stack, open a terminal window and connect to your&nbsp;Ubuntu&nbsp;server [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":""},"class_list":["post-44","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/reglisss.freeboxos.fr\/wordpress\/wp-json\/wp\/v2\/pages\/44","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/reglisss.freeboxos.fr\/wordpress\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/reglisss.freeboxos.fr\/wordpress\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/reglisss.freeboxos.fr\/wordpress\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/reglisss.freeboxos.fr\/wordpress\/wp-json\/wp\/v2\/comments?post=44"}],"version-history":[{"count":3,"href":"https:\/\/reglisss.freeboxos.fr\/wordpress\/wp-json\/wp\/v2\/pages\/44\/revisions"}],"predecessor-version":[{"id":116,"href":"https:\/\/reglisss.freeboxos.fr\/wordpress\/wp-json\/wp\/v2\/pages\/44\/revisions\/116"}],"wp:attachment":[{"href":"https:\/\/reglisss.freeboxos.fr\/wordpress\/wp-json\/wp\/v2\/media?parent=44"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}