ManagedCloud Servers

High performance handled and monitored by us 24/7/365. A complete solution to provide you with our in house expertise 24/7 tailored to your specific needs. We'll setup a bespoke server for your site using the latest tehnologies so you can get the most out of your hardware and get your website loading quickly and reliably. Find out more..

cPanelCloud Servers

Recommended - High performance cloud servers with no technical knowledge required. If you're hosting multiple websites already and you're looking to consolidate, or if you're looking to isolate yourself from the shared hosting environment but you don't have the time or knoweldge to manage a server, then the Managed cPanel Servers are for you. Find out more..

UnmanagedCloud Servers

Our unmanaged range gives you complete control at rock bottom prices and our cloud platform boasts super fast multipath 40Gb/s network, the latest Intel Xeon V3 CPUs and enterprise grade redundant SSDs. If you're a sysadmin look no further, we offer some of the best specification to price ratio servers available. Find out more..

Want your very own server? Get our 1GB memory, Xeon V4, 20GB SSD VPS for £10.00 / month.

View Plans

How to Install Booked Source on CentOS 7

Booked is a free and open source application written in PHP and MySQL that can be used to manage, record and track resources of any kind. It allows you to create schedules so users can find schedules available for resource use.

You can easily find available times for the resources as per your need. Booked comes with simple calender views that allows everyone to see resource availability at a glance.

Booked provides lots of features, some of them are listed below:

  1. Easy to use and easy to manage.
  2. Multiple languages, LDAP and Active Directory support.
  3. Easily integrates with Google Calender and Outlook.
  4. User and group quotas, roles and permissions.

In this tutorial, we will go through how to install Booked on CentOS 7 server.

Requirements

  • A server running CentOS 7.
  • A sudo user with root privileges setup on your server.

Getting Started

Before starting, update your system with the latest version by running the following command:

sudo yum update -y

Next, install other required packages with the following command:

sudo yum install vim wget unzip -y

Once you are done, you can proceed to install LAMP server.

Install LAMP Server

Next, you will need to install Apache, MariaDB and PHP on your server.

You can install all of them with the following command:

sudo yum install httpd mariadb-server php php-mysql -y

Once installation is completed, start apache and mariadb server and enable them to start at boot time with the following command:

sudo systemctl start httpd sudo systemctl enable httpd sudo systemctl start mariadb sudo systemctl enable mariadb

Configure Database

By default, MariaDB is not secured. You can secure it by running the mysql_secure_installation script:

sudo mysql_secure_installation

Answer all the questions as shown below:

Set root password? [Y/n] n
Remove anonymous users? [Y/n] y
Disallow root login remotely? [Y/n] y
Remove test database and access to it? [Y/n] y
Reload privilege tables now? [Y/n] y

Once MariaDB is secured, log in to the MySQL shell and create a database for booked:

mysql -u root -p

Enter your root password when prompt, then create a database for booked. It is recommended to set secure password:

MariaDB [(none)]> create database bookeddb;

Query OK, 1 row affected (0.00 sec)`

Next, create a database user and password for booked with the following command:

MariaDB [(none)]>CREATE USER 'bookeduser'@'localhost' IDENTIFIED BY 'password';

Query OK, 1 row affected (0.00 sec)`

Next, grant all privileges with the following command:

MariaDB [(none)]>GRANT ALL PRIVILEGES ONbookeddb.* TO 'bookeduser'@'localhost';

Next, run FLUSH PRIVILEGES command so that the privileges table will be reloaded by MySQL and we can use new credential:

MariaDB [(none)]>FLUSH PRIVILEGES; Query OK, 0 rows affected (0.00 sec)

Exit from the MySQL console by typing \q:

MariaDB [(none)]>\q Query OK, 0 rows affected (0.00 sec)

Once you are done, you can proceed to install Booked:

Install Booked

First, you will need to download the latest version of the booked from sourceforge.net site. Use the following command to download it easily:

wget https://ufpr.dl.sourceforge.net/project/phpscheduleit/Booked/2.6/booked-2.6.5.zip

Once the download is completed, extract the downloaded file with the following command:

unzip booked-2.6.5.zip

Next, move the extracted directory to the apache web root directory with the following command:

sudo mv booked /var/www/html/

Next, change the permissions of the booked directory with the following command:

sudo chown -R apache:apache /var/www/html/booked

Next, you will need to rename some configuration file:

cd /var/www/html/booked sudo cp config/config.dist.php config/config.php

Next, edit the config.php file:

sudo nano config/config.php

Make the following changes:

$conf['settings']['default.timezone'] = 'Asia/Kolkata';
$conf['settings']['admin.email'] = 'hitjethva@gmail.com';         // email address of admin user
$conf['settings']['admin.email.name'] = 'Hitesh Jethva';
$conf['settings']['script.url'] = 'http://yourdomain.com/Web';
$conf['settings']['database']['type'] = 'mysql';
$conf['settings']['database']['user'] = 'bookeduser';
$conf['settings']['database']['password'] = 'password';
$conf['settings']['database']['hostspec'] = '127.0.0.1';
$conf['settings']['database']['name'] = 'bookeddb';

Save and close the file when you are finished.

Next, you will need to import database schema and data. You can do this with the following command:

cd /var/www/html/bookedmysql -u bookeduser -p bookeddb < database_schema/create-schema.sql mysql -u bookeduser -p bookeddb < database_schema/create-data.sql

Once you are done, you can proceed to configure Apache for booked.

Configure Apache for Booked

Next, you will need to create a new apache virtual host file for booked. You can do this by creating booked.conf file inside /etc/httpd/conf.d/ directory:

sudo nano /etc/httpd/conf.d/booked.conf

Add the following lines:

<VirtualHost *:80>
ServerAdmin webmaster@yourdomain.com
DocumentRoot /var/www/html/booked
ServerName 192.168.15.193
ErrorLog /var/log/httpd/booked-error_log
CustomLog /var/log/httpd/booked-access_log combined

<Directory /var/www/html/booked/> DirectoryIndex index.php Options FollowSymLinks AllowOverride All Require all granted </Directory> </VirtualHost>

Save and close the file when you are finished, then restart apache server with the following command:

sudo systemctl restart httpd

Access Booked Web Interface

Before accessing the Booked web interface, you will need to set firewall rules for Booked to work properly.

You can do this by running the following command:

sudo firewall-cmd --permanent --zone=public --add-port=80/tcp

Next, reload the firewalld with the following command:

sudo firewall-cmd --reload

Finally, open your web browser and type the URL http://yourdomain.com/Web/register.php, you should see the following page:

Here, you will need to register a new account for booked, then click on the Register button. After the admin user created you will be redirected to Booked Scheduler admin dashboard.

Thats it. You have successfully installed Booked on your CentOS 7 server.

Want your very own server? Get our 1GB memory, Xeon V4, 20GB SSD VPS for £10.00 / month.

View Plans