Install Laravel in Ubuntu 22.04.3 LTS

Requirement

  1. Ctype PHP Extension
  2. cURL PHP Extension
  3. DOM PHP Extension
  4. Fileinfo PHP Extension
  5. Filter PHP Extension
  6. Hash PHP Extension
  7. Mbstring PHP Extension
  8. OpenSSL PHP Extension
  9. PCRE PHP Extension
  10. PDO PHP Extension
  11. Session PHP Extension
  12. Tokenizer PHP Extension
  13. XML PHP Extension

How to Install PHP?

 sudo apt install php php-cli php-common php-mbstring php-gd php-intl php-xml php-mysql php-zip php-curl php-tidy php-imagick -y   

How to check PHP version?

 php -v  

How to Install Composer?

 wget https://getcomposer.org/download/latest-stable/composer.phar  
   
 sudo chown root:root composer.phar  
   
 sudo chmod +x composer.phar  
   
 sudo mv composer.phar /usr/local/bin/composer  
   

How to Install Laravel?

 composer create-project laravel/laravel myblog       

Go to the myblog directory and check Artisan version

 cd myblog  
 php artisan --version   

How to Ran Laravel?

 php artisan serve   

Ran Laravel With Custom IP & Port?

 php artisan serve --host=0.0.0.0 --port=8080  

Next Post Previous Post
No Comment
Add Comment
comment url