Zikula is a free and open source web application framework written in PHP. You can deploy interactive and responsive websites using Zikula. The name Zikula is based on several zulu words which means fast, simple and easy.
Zikula makes small demands on the web server unlike other web frameworks. Zikula does not require it’s own database, in fact it allows you to use database tables with prefixes like MySQL, PostgreSQL.
Some functions of Zikula are listed below:
- Database abstraction by Doctrine
- Workflow API
- Form validation API
- Flexible legal system with any number of groups, components and instances
- Auth API for the integration of different authentication methods ( LDAP , OpenID , OAuth, etc.)
- Multilingualism via GNU gettext
Prerequisites
You’ll need a freshly installed CentOS 7 server with root user privileges over it to follow this guide. You can switch from non root user to root user using sudo -i
command.
Updating the System
Before going through the installation process it is highly recommended to update your system and upgrade all available packages run the command below and it’ll do the job for you.
yum -y update
Installing Apache Web Server
Once the system is updated, you can install the dependencies required. To install Zikula you will need to install the Apache web server along with MaraiDB and PHP with a few extensions.
Run the following command to install the Apache web server.
yum -y install httpd
Now you can start Apache and enable it to start at boot time, using the following commands.
systemctl start httpd.service systemctl enable httpd.service
You can check the status of Apache web server using the following command.
systemctl status httpd
You should see following output:
[root@Sajid ~]# systemctl status httpd
● httpd.service - The Apache HTTP Server
Loaded: loaded (/usr/lib/systemd/system/httpd.service; enabled; vendor preset: disabled)
Active: active (running) since Wed 2017-02-08 14:46:03 UTC; 22s ago
Docs: man:httpd(8)
man:apachectl(8)
Main PID: 10743 (httpd)
Status: "Total requests: 0; Current requests/sec: 0; Current traffic: 0 B/sec"
CGroup: /system.slice/httpd.service
├─10743 /usr/sbin/httpd -DFOREGROUND
├─10744 /usr/sbin/httpd -DFOREGROUND
├─10745 /usr/sbin/httpd -DFOREGROUND
├─10746 /usr/sbin/httpd -DFOREGROUND
├─10747 /usr/sbin/httpd -DFOREGROUND
└─10748 /usr/sbin/httpd -DFOREGROUNDFeb 08 14:46:03 ip-172-31-22-142 systemd[1]: Starting The Apache HTTP Server...
Feb 08 14:46:03 ip-172-31-22-142 systemd[1]: Started The Apache HTTP Server.
We will need to install MariaDB for database purpose for Zikula. MariaDB 5.5 is shipped in the default CentOS 7 repository, so just run this command to install MariaDB.
yum -y install mariadb-server
Now you’ll have to start the MariaDB service and enable it to start at the boot time like we have done before for apache server, to do so please run following command.
systemctl start mariadb.service systemctl enable mariadb.service
You can check status of mariaDB using this below given command and you should see following output.
systemctl status mariadb.service
[root@Sajid ~]# systemctl status mariadb.service
● mariadb.service - MariaDB database server
Loaded: loaded (/usr/lib/systemd/system/mariadb.service; enabled; vendor preset: disabled)
Active: active (running) since Wed 2017-02-08 14:47:40 UTC; 22s ago
Main PID: 18035 (mysqld_safe)
CGroup: /system.slice/mariadb.service
├─18035 /bin/sh /usr/bin/mysqld_safe --basedir=/usr
└─18192 /usr/libexec/mysqld --basedir=/usr --datadir=/var/lib/mysql --plugin-dir=/usr/lib64/mysql/plugin --log-error=/var/log/ma...Feb 08 14:47:38 ip-172-31-22-142 mariadb-prepare-db-dir[17956]: The latest information about MariaDB is available at http://mariadb.org/.
Feb 08 14:47:38 ip-172-31-22-142 mariadb-prepare-db-dir[17956]: You can find additional information about the MySQL part at:
Feb 08 14:47:38 ip-172-31-22-142 mariadb-prepare-db-dir[17956]: http://dev.mysql.com
Feb 08 14:47:38 ip-172-31-22-142 mariadb-prepare-db-dir[17956]: Support MariaDB development by buying support/new features from MariaDB
Feb 08 14:47:38 ip-172-31-22-142 mariadb-prepare-db-dir[17956]: Corporation Ab. You can contact us about this at sales@mariadb.com.
Feb 08 14:47:38 ip-172-31-22-142 mariadb-prepare-db-dir[17956]: Alternatively consider joining our community based development effort:
Feb 08 14:47:38 ip-172-31-22-142 mariadb-prepare-db-dir[17956]: http://mariadb.com/kb/en/contributing-to-the-mariadb-project/
Feb 08 14:47:39 ip-172-31-22-142 mysqld_safe[18035]: 170208 14:47:39 mysqld_safe Logging to '/var/log/mariadb/mariadb.log'.
Feb 08 14:47:39 ip-172-31-22-142 mysqld_safe[18035]: 170208 14:47:39 mysqld_safe Starting mysqld daemon with databases from /var/lib/mysql
Feb 08 14:47:40 ip-172-31-22-142 systemd[1]: Started MariaDB database server.
We recommend you make sure that this installation is secure and to do so run following command.
mysql_secure_installation
You’ll be asked to provide root password so enter appropriate password and answer yes to all questions by pressing Y.
Now you’ll have to create a database for Zikula so please follow the instructions.
mysql -u root -p
You’ll be asked to enter password so simply enter a password and now execute the following queries to create a new database.
CREATE DATABASE zikula_data;
The above query will create a database named zikula_data. For the database you can use any name you prefer in the place of zikula_data. Make sure that you use semicolon at the end of each query as a query always ends with a semicolon. Once the database is created you can create a new user and grant the required permissions to the user for the database.
CREATE USER 'zikula_user'@'localhost' IDENTIFIED BY 'StrongPassword';
The above query will create a user with username zikula_user. You can use any preferred username instead of zikula_user. Replace StrongPassword with a strong password.
Now provide the appropriate privileges to your database user over the database you have created. Run the following query to do so.
GRANT ALL PRIVILEGES ON zikula_data.* TO 'zikula_user'@'localhost';
Now run the following query to immediately apply the changes on the database privileges.
FLUSH PRIVILEGES;
Now you can exit from MariaDB prompt using following command.
exit
We will have to install PHP to install zikula as we know it is written in PHP. So run below given commands to install PHP.
yum -y install php php-common php-mysql php-mcrypt php-gd php-xml php-mbstring php-xmlrpc
If in case you don’t have wget and unzip package already nstalled on your server then you can install them using this command.
yum -y install wget unzip
Finally restart your apache web server to apply changes that we have just configured and to do so run following command.
systemctl restart httpd
Install Zikula
We have installed all the required dependencies to install zikula and now we are ready to download and install zikula on our CentOS 7 server. So first download the latest version of zikula CMS using wget command, simply run below given command it’ll do the job for you.
wget https://github.com/zikula/core/releases/download/1.4.6/Zikula_Core-1.4.6.build119.zip
Now extract the downloaded archive file using following command.
unzip Zikula_Core-1.4.6.build119.zip
Move the extracted files into the web root directory using following command.
mv Zikula_Core-1.4.6 /var/www/html/zikula
Next, You’ll have to set up proper ownership permission to the zikula.
chown -R apache:apache /var/www/html/zikula
Next you’ll have to modify firewall rules and if in case you don’t have firewalld services installed on your server then you can install it using yum -y install firewalld
and you can start it using systemctl start firewalld
Next run these below given command to modify the firewalld rules.
firewall-cmd --permanent --zone=public --add-port=80/tcp
firewall-cmd --reload
Access the Web Interface
Open up your favorite web browser and visit http://yourserverIP/install.php and then complete the installation wizard from your web browser.
You’ll be asked to select your language so select your language and then click on next button and then click on Accept license.
On the next page the script checks whether all the system requirements are met. If there is a problem, you will be informed. If everything is correct, click on the Next button.
Next, provide your database configuration details like your database name, database user, database type etc. and click on next button.
Next, select your installation type and complete installation wizard by providing your user admin details.
Conclusion
In this tutorial you’ve learned how to install Zikula CMS on your CentOS 7 server. You can deploy your interactive and editable websites using Zikula.