How to install Attendize on Ubuntu 16.04

We will explain to you how to install Attendize on Ubuntu 16.04, with MariaDB, PHP-FPM, and Nginx. Attendize is an open source platform ticketing and event management software written in PHP and the Laravel framework. This guide should work just as well on other Linux VPS systems, but has been tested and written for Ubuntu 16.04 VPS

Installing Attendize on Ubuntu 16.04 is an easy task if you follow the steps below carefully

1. Log in to your VPS via SSH

ssh [email protected]_IP

2. Update the system and install the required packages

sudo apt update && sudo apt -y upgrade
sudo apt install software-properties-common git nano

3. Install MariaDB 10.2

To add the MariaDB repository to the source list and install the latest MariaDB server, run the following commands:

sudo apt-key adv --recv-keys --keyserver hkp://keyserver.ubuntu.com:80 0xF1656F24C74CD1D8
sudo add-apt-repository 'deb [arch=amd64,i386,ppc64el] http://mirror.jaleco.com/mariadb/repo/10.2/ubuntu xenial main'
sudo apt update
sudo apt install -y mariadb-server

4. Protect the installation

When the installation is complete, run the following command to secure the installation:

mysql_secure_installation

5. Creating a new database

Next, we need to create a database to install Attendize.

mysql -uroot -p
MariaDB [(none)]> CREATE DATABASE attendize;
MariaDB [(none)]> GRANT ALL PRIVILEGES ON attendize.* TO 'attendize'@'localhost' IDENTIFIED BY 'сложный_пароль';
MariaDB [(none)]> FLUSH PRIVILEGES;
MariaDB [(none)]> q

6. Install PHP, composer and required PHP modules

To install the latest stable PHP version 7 and all required modules, run the command:

sudo add-apt-repository -y ppa:ondrej/php
sudo apt update
sudo apt -y install php7.0-fpm php7.0-cli php7.0-gd php7.0-mysql php7.0-mcrypt php-pear php7.0-curl

Composer is a dependency manager for PHP with which you can install packages. Composer will pull in all the libraries and dependencies you need for your project.

curl -sS https://getcomposer.org/installer | php
sudo mv composer.phar /usr/local/bin/composer

7. Installing Attendize on Ubuntu 16.04

Installing Attendize is pretty easy and straightforward, clone the Attendize repository from Github:

git clone https://github.com/attendize/attendize /var/www/myAttendize.ru

Go to catalog /var/www/myAttendize.ru and set the variables .env :

cd /var/www/myAttendize.ru
cp .env.example .env
nano .env
DB_TYPE=mysql
DB_HOST=localhost
DB_DATABASE=attendize
DB_USERNAME=attendize
DB_PASSWORD=сложный_пароль

8. Installing application dependencies

Installing all application dependencies:

composer install

9. Database setup

After Composer has downloaded the components, run the install command to transfer the database and create a user with administrator rights:

php artisan attendize:install
--------------------
Attempting to install Attendize v1.0.0
--------------------
Generating app key
Migrating database.
Database successfully migrated.
Seeding DB data
Data successfully seeded
--------------------
Please create an admin user.
--------------------

 Enter first name::
 > Andrey

 Enter last name::
 > Ex

 Enter your email::
 > [email protected]

 Enter a password::
 >

Admin User Successfully Created

          _   _                 _ _
     /  | | | |               | (_)
    /   | |_| |_ ___ _ __   __| |_ _______
   / / | __| __/ _  '_  / _` | |_  / _ 
  / ____  |_| ||  __/ | | | (_| | |/ /  __/
 /_/    ___|_____|_| |_|__,_|_/______|

Success! You can now run Attendize

Finally change the ownership of the directory /var/www/myAttendize.com on www-data

chown -R www-data: /var/www/myAttendize.ru

10. Installing and configuring Nginx

Install the latest stable version of Nginx from the official Ubuntu repositories:

sudo apt -y install nginx

Then create a new Nginx server block:

sudo nano /etc/nginx/sites-available/myAttendize.ru
server {
    listen 80;
    server_name myAttendize.ru;
    root /var/www/myAttendize.ru/public;

    add_header X-Frame-Options "SAMEORIGIN";
    add_header X-XSS-Protection "1; mode=block";
    add_header X-Content-Type-Options "nosniff";

    index index.html index.htm index.php;

    charset utf-8;

    location / {
        try_files $uri $uri/ /index.php?$query_string;
    }

    location = /favicon.ico { access_log off; log_not_found off; }
    location = /robots.txt  { access_log off; log_not_found off; }

    error_page 404 /index.php;

    location ~ .php$ {
        fastcgi_split_path_info ^(.+.php)(/.+)$;
        fastcgi_pass unix:/var/run/php/php7.0-fpm.sock;
        fastcgi_index index.php;
        include fastcgi_params;
    }

    location ~ /.(?!well-known).* {
        deny all;
    }
}

Activate the server block by creating a symbolic link:

sudo ln -s /etc/nginx/sites-available/myAttendize.ru /etc/nginx/sites-enabled/myAttendize.ru

11. Checking the Nginx configuration and restarting Nginx:

sudo nginx -t
sudo service nginx restart

Open up https://myAttendize.com/in your favorite web browser and you should see a fresh install of Attendize.

That’s all. You have successfully installed Attendize on Ubuntu 16.04. For more information on how to manage your Attendize installation, please refer to the official Attendize documentation (https://www.attendize.com/documentation.php).

Sidebar