{"id":17448,"date":"2015-09-11T16:22:56","date_gmt":"2015-09-11T21:22:56","guid":{"rendered":"https:\/\/secure.rosehosting.com\/blog\/?p=17448"},"modified":"2022-12-14T04:49:32","modified_gmt":"2022-12-14T10:49:32","slug":"how-to-install-zenphoto-gallery-cms-on-a-centos-7-vps","status":"publish","type":"post","link":"https:\/\/www.rosehosting.com\/blog\/how-to-install-zenphoto-gallery-cms-on-a-centos-7-vps\/","title":{"rendered":"How to install Zenphoto Gallery CMS on CentOS 7"},"content":{"rendered":"
Zenphoto is free and open-source standalone content management system (CMS) for creating gallery focused websites. Zenphoto is feature rich PHP based application and it has everything you need to manage your own photo galleries. In this blog tutorial we will install Zenphoto on CentOS 7 VPS<\/a> with Apache, MariaDB and PHP<\/p>\n To be eligible to run Zenphoto, you need to have the following requirements installed on your server: Log in to your CentOS VPS via SSH as user root<\/p>\n and make sure that all packages are up to date by executing the following command<\/p>\n Run the following command to install MariaDB database server<\/p>\n Start the MariaDB database server and enable it to start at the boot time<\/p>\n Run the ‘mysql_secure_installation’ script to secure the database server and set your MariaDB root password<\/p>\n Log in to the MariaDB server using the ‘root’ user and create new database end user.<\/p>\n Don’t forget to replace ‘PASSWORD’ with a strong password.<\/p>\n Next, we will install Apache web server<\/p>\n Start the Apache web server and add it to automatically start on the system start-up<\/p>\n Now we need to install PHP among with few PHP modules<\/p>\n Install ImageMagic package and ImageMagic PHP extension<\/p>\n Once all requirements are installed. download the latest stable release of Zenphoto from their official website.<\/p>\n Unpack the downloaded zip archive to the document root directory on your server<\/p>\n If you are not sure where is your document root directory you can use the following command to find out<\/p>\n Change the current working directory and rename the unpacked Zenphoto directory<\/p>\n Change the ownership of the directory<\/p>\n Next, create Apache virtual host for your domain. Create ‘\/etc\/httpd\/conf.d\/vhosts.conf’ directory with the following content<\/p>\n and create the virtual host<\/p>\n Restart the Apache web server for the changes to take effect.<\/p>\n Open your favorite web browser and navigate to your Zenphoto gallery at http:\/\/yourdomain.com . It will automatically run the installation script and will prompt you to enter the MySQL information of the database we created in this tutorial.<\/p>\n Of course you don\u2019t have to do any of this if you use one of our Linux VPS Hosting<\/a> services, in which case you can simply ask our expert Linux admins to install Zenphoto for you. They are available 24\u00d77 and will take care of your request immediately.<\/p>\n PS.<\/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":" Zenphoto is free and open-source standalone content management system (CMS) for creating gallery focused websites. Zenphoto is feature rich PHP … <\/p>\n
\n– A web server – Apache or Nginx
\n– PHP version 5.2 or newer with GD and imagick extensions.
\n– MySQL\/MariaDB database version 5 or newer.<\/p>\nssh root@IP<\/pre>\n
yum -y update<\/pre>\n
yum install mariadb mariadb-server<\/pre>\n
systemctl start mariadb\r\nsystemctl enable mariadb<\/pre>\n
mysql -u root -p\r\n\r\nCREATE DATABASE zenphoto;\r\nCREATE USER 'zenphotouser'@'localhost' IDENTIFIED BY 'PASSWORD';\r\nGRANT ALL PRIVILEGES ON `zenphoot`.* TO 'zenphotouser'@'localhost';\r\nFLUSH PRIVILEGES;<\/pre>\n
yum install httpd<\/pre>\n
systemctl start httpd\r\nsystemctl enable httpd<\/pre>\n
yum install php php-gd php-common<\/pre>\n
yum install ImageMagick\r\npecl install imagick\r\necho \"extension=imagick.so\" > \/etc\/php.d\/imagick.ini<\/pre>\n
wget https:\/\/github.com\/zenphoto\/zenphoto\/archive\/zenphoto-1.4.9.zip<\/pre>\n
unzip enphoto-1.4.9.zip -d \/var\/www\/html\/<\/pre>\n
grep -i '^documentroot' \/etc\/httpd\/conf\/httpd.conf\r\nDocumentRoot \"\/var\/www\/html\"<\/pre>\n
cd \/var\/www\/html\/\r\nmv zenphoto-zenphoto-1.4.9\/ zenphoto<\/pre>\n
chown -R apache:apache zenphoto<\/pre>\n
vim \/etc\/httpd\/conf.d\/vhosts.conf\r\n\r\nIncludeOptional vhosts.d\/*.conf<\/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\/zenphoto\/\"\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\/zenphoto\/\">\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