• Home
  • Ubuntu 16.04
    • Whats New ?
    • Install JAVA 8
    • Setup LAMP Stack
    • Install LEMP Stack
    • Install Node.js
    • Install Git
    • Move Unity Launcher to Bottom
  • FeedBack
  • Funny Tools
  • Tutorials
    • Linux Distributions
      • CentOS
      • Debian
      • Fedora
      • LinuxMint
    • Monitoring Tools
      • Monit
      • Nagios
      • NRPE
    • Network Services
      • DHCP
      • DNS
      • FTP
    • Databases
      • MySQL
      • MariaDB
      • MongoDB
      • PostgreSQL
      • SQL Server
    • Amazon Web Services
  • Submit Article
  • About Us
TecAdmin.net
  • Home
  • Ubuntu 16.04
    • Whats New ?
    • Install JAVA 8
    • Setup LAMP Stack
    • Install LEMP Stack
    • Install Node.js
    • Install Git
    • Move Unity Launcher to Bottom
  • FeedBack
  • Funny Tools
  • Tutorials
    • Linux Distributions
      • CentOS
      • Debian
      • Fedora
      • LinuxMint
    • Monitoring Tools
      • Monit
      • Nagios
      • NRPE
    • Network Services
      • DHCP
      • DNS
      • FTP
    • Databases
      • MySQL
      • MariaDB
      • MongoDB
      • PostgreSQL
      • SQL Server
    • Amazon Web Services
  • Submit Article
  • About Us
18 November 2015

How to Install Zend Framework 2.5 on Ubuntu, Debian & LinuxMint

Written by Rahul K. | November 18, 2015
PHP Framework Framework, php, php framework, zend, zend2

Zend Framework 2 is an open source framework for developing web applications and services. It requires PHP >= 5.3. It uses 100% object-oriented code. This tutorial will help you to install Zend Framework 2 on your Ubuntu, Debian and LinuxMint systems.

1. Install Apache & PHP

First make sure that you have installed Apache2 and PHP5 on your system. If not have already installed use following command to install it.

$ sudo apt-get update
$ sudo apt-get install apache2 php5 php5-cli

2. Install PHP Composer

After installing Apache2 and PHP5 on your system, you need to install PHP Composer on your system. Use the following set of commands to install it.

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

3. Install Zend Framework 2

There are many ways available to install Zend Framework 2 on your system but I select following way. which looks easier to me.

$ cd /var/www
$ sudo git clone git://github.com/zendframework/ZendSkeletonApplication.git
$ sudo cd ZendSkeletonApplication
$ sudo composer install

4. Start Web Server

Following command will start a PHP-CLI web server. This is useful for temporarily testing and helpful for development purpose.

$ php -S 0.0.0.0:8080 -t public/ public/index.php

Now access http://localhost:8080 in web browser.

Install Zend Framework

5. Configure Apache Server

Let’s configure Zend Framework 2 as web application with Apache2. Create a configuration file in Apache server for Zend2 installation.

$ sudo vi /etc/apache2/sites-available/zend2.example.com.conf

and add the following content in file. Make the necessary changes as per your setup and Apache version.

<VirtualHost *:80>
   ServerName zend2.example.com
   DocumentRoot /var/www/ZendSkeletonApplication/public

   <Directory /var/www/ZendSkeletonApplication/public>
       AllowOverride All
#      Require all granted   # For Apache version >=2.4
       Order allow,deny      # For Apache version < 2.4
       Allow from all        # For Apache version < 2.4
   </Directory>
</VirtualHost>

Now enable newly created site using following command.

$ sudo a2ensite zend2.example.com
$ sudo service apache2 reload

All done! Enjoy developement with Zend Framework 2.

Share it!
Share on Facebook
Share on Twitter
Share on Google+
Share on Reddit
Share on Tumblr
Rahul K.
Rahul K.
Connect on Facebook Connect on Twitter Connect on Google+

I, Rahul Kumar am the founder and chief editor of TecAdmin.net. I am a Red Hat Certified Engineer (RHCE) and working as an IT professional since 2009..

Related Posts

  • How do I Convert Date Format in PHP

  • How to Install and Configure phpMyAdmin on Debian 9/8

  • How to Install and Use PHP Composer on Debian 9/8

  • How to Install Redis Cache Server on CentOS 7/6

  • How To Install PHP (7.2, 7.1 & 5.6) on Debian 9 Stretch

1 Comment

  1. muna Reply to muna
    July 16, 2017 at 8:46 am

    Hi ,
    I am getting Internal Server Error error when run the site zend2.example.com

Leave a Reply

Cancel reply

Popular Posts

  • How to Install JAVA 8 on Ubuntu 18.04/16.04, LinuxMint 18/17
  • How to Install s3cmd in Linux and Manage Amazon s3 Buckets
  • How to Install AnyDesk on Ubuntu, Debian and LinuxMint (Alternative of TeamViewer)
  • How to Setup Selenium with ChromeDriver on Ubuntu 16.04
  • How to Install MySQL on macOS Sierra and High Sierra
All rights reserved. © 2013-2018 TecAdmin.net. This site uses cookies. By using this website you agree our term and services