Friday, 24 May 2013

Install Laravel 4 on Ubuntu


Recently i willing to learn laravel framework because of its rich features towards web development and that borrows a lot from Rails.In previous i have used the CodeIgniter for my projects.

This post is mainly for beginners, To Install laravel 4 on ubuntu 12.04

Installing Composer:

To install composer via terminal , type the command

# curl -sS https://getcomposer.org/installer | php

Move the composer to usr/local/bin to access composer globally

# mv composer.phar /usr/local/bin/composer
check if the composer is available globally by simply type
#  composer

Installing Laravel:

To install laravel via Git Clone repository first you have to install Git on your machine , if Git is installed in your machine then clone Laravel git repository as

# git clone https://github.com/laravel/laravel.git /opt/lampp/htdocs/lara_test1
 here lara_test1 our newly created project directory for installing laravel , To view the files inside the newly created project folder
#  cd  /opt/lampp/htdocs/lara_test1
#  ls
 To install composer to our project directory
#  composer install
while installing composer if the error thrown such as 
               Laravel requires the Mcrypt PHP extension.
 then you have to install the mycript library , for that simply use
# sudo apt-get install php5-mcrypt
and after that again re-install composer , it may fix issues.

And finally  open your web browser and simply go to
  http://localhost/lara_test1/public/
 Also , dont forget to change the persmission of folders within app/storage .
 

 Every thing goes fine, you welcome with laravel's  default message with Logo.


You have arrived.

1 comment: