{"id":3236,"date":"2018-04-06T17:32:24","date_gmt":"2018-04-06T13:32:24","guid":{"rendered":"https:\/\/www.howtoforge.com\/tutorial\/ubuntu-apache-couch-cms\/"},"modified":"2018-04-06T17:32:24","modified_gmt":"2018-04-06T13:32:24","slug":"how-to-install-couch-cms-on-ubuntu-16-04-lts","status":"publish","type":"post","link":"https:\/\/afaghhosting.net\/blog\/how-to-install-couch-cms-on-ubuntu-16-04-lts\/","title":{"rendered":"How to Install Couch CMS on Ubuntu 16.04 LTS"},"content":{"rendered":"<p>Couch CMS is a free, open source and simple Content Management System that can be used to design beautiful websites without any knowledge of PHP. Couch CMS include integrated RSS feeds, forms, custom pages and PayPal integration. Couch CMS comes with lots of features including, Editable Regions, Comments, Cloned Pages, Auto-validating Forms, SEO Friendly Links, RSS Feeds, URL Cloaking and much more.<\/p>\n<p>In this tutorial, we will learn how to install Couch CMS on Ubuntu 16.04.<\/p>\n<h2 id=\"requirements\">Requirements<\/h2>\n<ul>\n<li>A server running Ubuntu 16.04.<\/li>\n<li>A non-root user with sudo privileges.<\/li>\n<\/ul>\n<h2 id=\"update-the-system\">Update the System<\/h2>\n<p>First, update your system&#8217;s package repository to the latest version by running the following command:<\/p>\n<p class=\"command\">sudo apt-get update -y<br \/>sudo apt-get upgrade -y<\/p>\n<p>Once the repository is updated, restart the system to apply all the changes.<\/p>\n<h2 id=\"install-lampp-server\">Install LAMPP Server<\/h2>\n<p>Next, you will need to install Apache web server, PHP, and MariaDB to your system. You can install all of them by running the following command:<\/p>\n<p class=\"command\">sudo apt-get install apache2 mariadb-server libapache2-mod-php7.0 php7.0 php7.0-gd php7.0-mbstring php7.0-mysqlnd -y<\/p>\n<p>Once all the packages are installed, start Apache and MariaDB service and enable them to start on boot with the following command:<\/p>\n<p class=\"command\">sudo systemctl start apache2<br \/>sudo systemctl enable apache2<br \/>sudo systemctl start mysql<br \/>sudo systemctl enable mysql<\/p>\n<h2 id=\"configure-database-for-couchcms\">Configure Database for CouchCMS<\/h2>\n<p>By default, MariaDB is not secure. So you will need to secure it first. You can secure it by using the mysql_secure_installation script.<\/p>\n<p class=\"command\">sudo mysql_secure_installation<\/p>\n<p>This script will set a root password, remove anonymous users, disallow remote root login, and remove the test database and access to secure MariaDB as shown below:<\/p>\n<pre>Set root password? [Y\/n] y&#13;\nRemove anonymous users? [Y\/n] y&#13;\nDisallow root login remotely? [Y\/n] y&#13;\nRemove test database and access to it? [Y\/n] y&#13;\nReload privilege tables now? [Y\/n] y&#13;\n<\/pre>\n<p>Once the MariaDB is secured, create a database for Couch CMS.<\/p>\n<p>First, log in to the MariaDB console with the following command:<\/p>\n<p class=\"command\">mysql -u root -p<\/p>\n<p>You will be prompt for a password, enter your root password and create a database for Couch CMS:<\/p>\n<p class=\"command\">MariaDB [(none)]&gt; CREATE DATABASE couchdb CHARACTER SET utf8 COLLATE utf8_general_ci;<\/p>\n<p>Next, create a user for OctoberCMS and grant all privileges to the Couch CMS with the following command:<\/p>\n<p class=\"command\">MariaDB [(none)]&gt; GRANT ALL PRIVILEGES ON couchdb.* TO &#8216;couch&#8217;@&#8217;localhost&#8217; IDENTIFIED BY &#8216;password&#8217;;<\/p>\n<p>Next, flush the privileges with the following command:<\/p>\n<p class=\"command\">MariaDB [(none)]&gt; flush privileges;<\/p>\n<p>Finally, exit from the MariaDB console using the following command:<\/p>\n<p class=\"command\">MariaDB [(none)]&gt; quit<\/p>\n<p>Once the database is configured, you can proceed to the next step.<\/p>\n<h2 id=\"install-couchcms\">Install CouchCMS<\/h2>\n<p>First, you will need to download the latest version of the Couch CMS from GIT repository. You can download it with the following command:<\/p>\n<p class=\"command\">wget https:\/\/github.com\/CouchCMS\/CouchCMS\/archive\/master.zip<\/p>\n<p>Once the download is completed, unzip the downloaded file using the following command:<\/p>\n<p class=\"command\">unzip master.zip<\/p>\n<p>Next, copy the extracted directory to the Apache root directory with the following command:<\/p>\n<p class=\"command\">sudo cp -r CouchCMS-master\/couch \/var\/www\/html\/<\/p>\n<p>Next, give proper permission to the couch directory:<\/p>\n<p class=\"command\">sudo chown -R www-data:www-data \/var\/www\/html\/couch<br \/>sudo chmod -R 777 \/var\/www\/html\/couch<\/p>\n<p>Next, change the directory to the couch and rename config.example.php file to config.php:<\/p>\n<p class=\"command\">cd \/var\/www\/html\/couch<br \/>sudo cp config.example.php config.php<\/p>\n<p>Next, open config.php file and add the database credentials:<\/p>\n<p class=\"command\">sudo nano config.php<\/p>\n<p>Change the file as shown below:<\/p>\n<pre> \/\/ If necessary, define the full URL of your site including the subdomain, if any.&#13; \/\/ V.IMP: Don't forget the trailing slash!&#13; define( 'K_SITE_URL', 'http:\/\/192.168.0.102\/' );&#13;\n&#13; \/\/ Name of the database&#13; define( 'K_DB_NAME', 'couchdb' );&#13; \/\/ 5.&#13; \/\/ Database username&#13; define( 'K_DB_USER', 'couch' );&#13; \/\/ 6.&#13; \/\/ Database password&#13; define( 'K_DB_PASSWORD', 'password' );&#13; \/\/ 7.&#13; \/\/ MySQL hostname (it will usually be 'localhost')&#13; define( 'K_DB_HOST', 'localhost' );&#13;\n<\/pre>\n<p>Save and close the file when you are finished, then enable rewrite module with the following command:<\/p>\n<p class=\"command\">sudo a2enmod rewrite<\/p>\n<h2 id=\"finally-restart-apache-service-to-apply-all-the-changes\">Finally, restart Apache service to apply all the changes:<\/h2>\n<p class=\"command\">sudo systemctl restart apache2<\/p>\n<h2 id=\"access-couch-cms\">Access Couch CMS<\/h2>\n<p>Couch CMS is now installed, it&#8217;s time to access Couch CMS<\/p>\n<p>Open your web browser and type the URL <strong>http:\/\/192.168.0.102\/couch<\/strong>, you will be redirected to the following page:<\/p>\n<p><a class=\"fancybox\" id=\"img-Page1\" href=\"https:\/\/www.howtoforge.com\/images\/how_to_install_couch_cms_ubuntu_1604\/big\/Page1.png\" target=\"_blank\" rel=\"noopener\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/afaghhosting.net\/blog\/wp-content\/uploads\/2018\/04\/how-to-install-couch-cms-on-ubuntu-16-04-lts.png\" alt=\"Access Couch CMS\" width=\"550\" height=\"284\" title=\"\"><\/a><\/p>\n<p>Here, provide your admin username and password, then click on the <strong>Install<\/strong> button, Once the installation is completed successfully, you should see the following page:<\/p>\n<p><a class=\"fancybox\" id=\"img-Page2\" href=\"https:\/\/www.howtoforge.com\/images\/how_to_install_couch_cms_ubuntu_1604\/big\/Page2.png\" target=\"_blank\" rel=\"noopener\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/afaghhosting.net\/blog\/wp-content\/uploads\/2018\/04\/how-to-install-couch-cms-on-ubuntu-16-04-lts-1.png\" alt=\"Installation of couch cms successful\" width=\"550\" height=\"211\" title=\"\"><\/a><\/p>\n<p>Now, click on the <strong>login<\/strong> button, you should see the following page:<\/p>\n<p><a class=\"fancybox\" id=\"img-Page3\" href=\"https:\/\/www.howtoforge.com\/images\/how_to_install_couch_cms_ubuntu_1604\/big\/Page3.png\" target=\"_blank\" rel=\"noopener\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/afaghhosting.net\/blog\/wp-content\/uploads\/2018\/04\/how-to-install-couch-cms-on-ubuntu-16-04-lts-2.png\" alt=\"Login to the admin dashboard\" width=\"550\" height=\"269\" title=\"\"><\/a><\/p>\n<p>Here, provide your admin username and password, then click on the <strong>Log In button<\/strong>, you should see the Couch CMS dashboard in the following image:<\/p>\n<p><a class=\"fancybox\" id=\"img-Page4\" href=\"https:\/\/www.howtoforge.com\/images\/how_to_install_couch_cms_ubuntu_1604\/big\/Page4.png\" target=\"_blank\" rel=\"noopener\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/afaghhosting.net\/blog\/wp-content\/uploads\/2018\/04\/how-to-install-couch-cms-on-ubuntu-16-04-lts-3.png\" alt=\"Couch CMS dashboard\" width=\"550\" height=\"285\" title=\"\"><\/a><\/p>\n<div>\n<p><b>Share this page:<\/b><\/p>\n<p>\n<a href=\"https:\/\/www.facebook.com\/sharer.php?u=https%3A%2F%2Fwww.howtoforge.com%2Ftutorial%2Fubuntu-apache-couch-cms%2F\" target=\"_blank\" rel=\"nofollow noopener noreferrer\"><img decoding=\"async\" src=\"https:\/\/afaghhosting.net\/blog\/wp-content\/uploads\/2018\/04\/how-to-install-couch-cms-on-ubuntu-16-04-lts-4.png\" height=\"20\" alt=\"\" title=\"\"><\/a><br \/>\n<a href=\"https:\/\/twitter.com\/intent\/tweet?url=https%3A%2F%2Fwww.howtoforge.com%2Ftutorial%2Fubuntu-apache-couch-cms%2F&amp;text=How+to+Install+Couch+CMS+on+Ubuntu+16.04+LTS&amp;via=howtoforgecom&amp;related=howtoforgecom\" target=\"_blank\" rel=\"nofollow noopener noreferrer\"><img decoding=\"async\" src=\"https:\/\/afaghhosting.net\/blog\/wp-content\/uploads\/2018\/04\/how-to-install-couch-cms-on-ubuntu-16-04-lts-5.png\" height=\"20\" alt=\"\" title=\"\"><\/a><br \/>\n<a href=\"https:\/\/twitter.com\/howtoforgecom\/\" target=\"_blank\" rel=\"nofollow noopener noreferrer\"><img decoding=\"async\" src=\"https:\/\/afaghhosting.net\/blog\/wp-content\/uploads\/2018\/04\/how-to-install-couch-cms-on-ubuntu-16-04-lts-6.png\" height=\"20\" alt=\"\" title=\"\"><\/a><br \/>\n<a href=\"https:\/\/plus.google.com\/share?url=https%3A%2F%2Fwww.howtoforge.com%2Ftutorial%2Fubuntu-apache-couch-cms%2F\" target=\"_blank\" rel=\"nofollow noopener noreferrer\"><img decoding=\"async\" src=\"https:\/\/afaghhosting.net\/blog\/wp-content\/uploads\/2018\/04\/how-to-install-couch-cms-on-ubuntu-16-04-lts-7.png\" height=\"20\" alt=\"\" title=\"\"><\/a>\n<\/p>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>Couch CMS is a free, open source and simple Content Management System that can be used to design beautiful websites without any knowledge of PHP. Couch CMS include integrated RSS feeds, forms, custom pages and PayPal integration. Couch CMS comes with lots of features including, Editable Regions, Comments, Cloned Pages, Auto-validating Forms, SEO Friendly Links, &hellip;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[36],"tags":[],"class_list":["post-3236","post","type-post","status-publish","format-standard","hentry","category-36"],"_links":{"self":[{"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/posts\/3236","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/comments?post=3236"}],"version-history":[{"count":0,"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/posts\/3236\/revisions"}],"wp:attachment":[{"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/media?parent=3236"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/categories?post=3236"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/tags?post=3236"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}