Install Laravel on Linux

There are several ways to install the Laravel framework locally, on a Linux machine:

cPanel Hosting from WebhostFace
  1. Using Composer (you can lookup how to install Composer here)
    composer create-project --prefer-dist laravel/laravel {ROOT_DIRECTORY}*
  2. Using Git:
    cd {ROOT_DIRECTORY}
    git clone https://github.com/laravel/laravel.git
    cp .env.example .env
    php artisan key:generate
    composer install

    Using Git you will also have to fill the .env file that we copied with the local settings that you use.
    alternatively, you can change the PHP config in config/database.php

  3. Manual Database Config:
    'mysql' => [
        'read' => [
            'host' => [
                '192.168.1.1',
                '196.168.1.2',
            ],
        ],
        'write' => [
            'host' => [
                '196.168.1.3',
             ],
        ],
        'sticky'    => true,
        'driver'    => 'mysql',
        'database'  => 'DATABASE NAME',
        'username'  => 'DATABASE USER',
        'password'  => 'DATABASE PASSWORD',
        'charset'   => 'utf8mb4',
        'collation' => 'utf8mb4_unicode_ci',
        'prefix'    => '',
    ],

After this Laravel will be installed and accessible for your local server through the /public directory.

Start your online Laravel project with our Laravel Hosting and benefit from easy Composer Installation and guidelines. Now with a new great price as we all know how important is to start your new project without investing a large amount of money!