{"id":18969,"date":"2016-05-11T07:51:10","date_gmt":"2016-05-11T12:51:10","guid":{"rendered":"https:\/\/www.rosehosting.com\/blog\/?p=18969"},"modified":"2022-12-29T11:15:35","modified_gmt":"2022-12-29T17:15:35","slug":"how-to-install-phpwcms-on-a-centos-7-vps","status":"publish","type":"post","link":"https:\/\/www.rosehosting.com\/blog\/how-to-install-phpwcms-on-a-centos-7-vps\/","title":{"rendered":"How to Install phpwcms on a CentOS 7 VPS"},"content":{"rendered":"
<\/p>\n
phpwcms is a free and open source content management system and PHP development framework. It is very powerful, fast and flexible. It’s used by developers to create thousands of websites around the world. With its extensibility, phpwcms can create powerful websites with a lot of features. The admin area is easy to use with great user interface and beginners can easily adapt to it. In this tutorial we will guide you through the process of installing phpwcms on a CentOS 7 VPS<\/a> with Apache web server, PHP and MariaDB<\/p>\n To start the installation, login to your CentOS 7 server as user root<\/p>\n As usual, run the following command to update all installed packages<\/p>\n Next, install Apache web server<\/p>\n Once the installation of the web server is completed, start it and set it to start automatically on boot.<\/p>\n phpwcms is a PHP based application and we need to install PHP with the ‘mysql’ extensions installed<\/p>\n Run the following command on your terminal to install MariaDB server on your CentOS 7 server<\/p>\n Once the installation is completed start the MariaDB server and set it to start on system boot<\/p>\n Then, run the phpwcms requires an empty database, so login to the MariaDB server with the root user and create a new user and database that will be used by phpwcms to store information<\/p>\n Don\u2019t forget to replace \u2018PASSWORD\u2019 with an actual strong password.<\/p>\n Download the latest available phpwcms release from their official website to your server. Make sure that you are downloading the full release, and not a patch package.<\/p>\n Unpack the downloaded ZIP archive to the document root directory on your server<\/p>\n This will create a new directory for phpwcms with the version number. Change the name of the directory to something simpler.<\/p>\n Set the Apache user as the owner of the phpwcms files and directories<\/p>\n On the next step we will create an Apache virtual host for your phpwcms based website. Create a \u2018\/etc\/httpd\/conf.d\/vhosts.conf\u2019 file with the following content:<\/p>\n Create a ‘vhosts.d\/’ directory<\/p>\n and create the virtual host with the following content<\/p>\n Save the file and restart the Apache web server for the changes to take effect.<\/p>\n With this step the installation from the command line is completed. Now, open a web browser and navigate it to http:\/\/yourdomain.com\/setup\/index.php, accept their terms and conditions and follow the on-screen instructions to complete the phpwcms installation.<\/p>\n Of course you don\u2019t have to do any of this if you use one of our Blazing-Fast CMS Hosting<\/a> services, in which case you can simply ask our expert Linux admins to install phpwcms<\/strong> for you. They are available 24\u00d77 and will take care of your request immediately.<\/p>\n PS<\/strong><\/span>.<\/strong><\/span> If you liked this post please share it with your friends on the social networks using the buttons on the left or simply leave a reply below. Thanks.<\/p>\n","protected":false},"excerpt":{"rendered":" phpwcms is a free and open source content management system and PHP development framework. It is very powerful, fast and … <\/p>\nssh root@IP<\/pre>\n
yum -y update<\/pre>\n
yum -y install httpd<\/pre>\n
systemctl start httpd\r\nsystemctl enable httpd<\/pre>\n
yum -y install php php-mysql<\/pre>\n
yum -y install mariadb mariadb-server<\/pre>\n
systemctl start mariadb\r\nsystemctl enable mariadb<\/pre>\n
mysql_secure_installation script<\/code>. This script will help you to improve the security of your MariaDB installation and set your MariaDB root password.<\/p>\n
mysql -u root -p\r\n\r\nCREATE DATABASE phpwcms;\r\nCREATE USER 'phpwcmsuser'@'localhost' IDENTIFIED BY 'PASSWORD';\r\nGRANT ALL PRIVILEGES ON `phpwcms`.* TO 'phpwcmsuser'@'localhost';\r\nFLUSH PRIVILEGES;\r\nexit<\/pre>\n
wget https:\/\/github.com\/slackero\/phpwcms\/archive\/phpwcms-1.8.2.zip<\/pre>\n
unzip phpwcms-1.8.2.zip -d \/var\/www\/html\/<\/pre>\n
cd \/var\/www\/html\/\r\nmv phpwcms-phpwcms-1.8.2 phpwcms<\/pre>\n
chown -R apache: \/var\/www\/html\/phpwcms<\/pre>\n
IncludeOptional vhosts.d\/*.conf<\/pre>\n
mkdir \/etc\/httpd\/vhosts.d\/<\/pre>\n
vim \/etc\/httpd\/vhosts.d\/yourdomain.com.conf\r\n\r\n<VirtualHost YOUR_SERVER_IP:80>\r\nServerAdmin webmaster@yourdomain.com\r\nDocumentRoot \"\/var\/www\/html\/phpwcms\/\"\r\nServerName yourdomain.com\r\nServerAlias www.yourdomain.com\r\nErrorLog \"\/var\/log\/httpd\/yourdomain.com-error_log\"\r\nCustomLog \"\/var\/log\/httpd\/yourdomain.com-access_log\" combined\r\n\r\n<Directory \"\/var\/www\/html\/phpwcms\/\">\r\nDirectoryIndex index.html index.php\r\nOptions FollowSymLinks\r\nAllowOverride All\r\nRequire all granted\r\n<\/Directory>\r\n<\/VirtualHost><\/pre>\n
systemctl restart httpd<\/pre>\n
\n