Last active
August 30, 2024 15:04
-
-
Save Raza9798/6b0841fa8c735ec27bc347c62a27ca23 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# LINUX REPOSITORY UPDATE & UPGRADE | |
sudo apt-get update | |
sudo ap-get upgrade | |
# PHP INSTALLATION | |
sudo apt-get install php8.3-cli | |
sudo apt-get install php8.3-xml php8.3-dom php8.3-gd php8.3-mysql php8.3-mbstring | |
=> php -v | |
# APACHE SERVER INSTALLATION | |
sudo apt-get install apache2 | |
=> sudo systemctl status apache2 | |
# COMPOSER INSTALLATION | |
php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');" | |
php -r "if (hash_file('sha384', 'composer-setup.php') === 'dac665fdc30fdd8ec78b38b9800061b4150413ff2e3b6f88543c636f7cd84f6db9189d43a81e5503cda447da73c7e5b6') { echo 'Installer verified'; } else { echo 'Installer corrupt'; unlink('composer-setup.php'); } echo PHP_EOL;" | |
php composer-setup.php | |
php -r "unlink('composer-setup.php');" | |
sudo mv composer.phar /usr/local/bin/composer | |
=> composer | |
# NODE INSTALLATION | |
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.7/install.sh | bash | |
.. restart the terminal (close and open again) | |
nvm install 22 | |
=> node -v | |
=> npm -v | |
# GIT INSTALLATION | |
sudo apt-get install git | |
# LARAVEL GLOABL INSTALLATION | |
composer global require "laravel/installer" | |
cd | |
sudo nano .bashrc | |
.. add following line and save the file | |
export PATH="$PATH:$HOME/.config/composer/vendor/bin" | |
source ~/.bashrc | |
=> laravel new blog | |
#MYSQL INSTALATTION | |
sudo apt install mysql-server | |
sudo mysql_secure_installation | |
.. Connecting to MySQL using a blank password => y | |
.. There are three levels of password validation policy => 0 | |
.. Remove anonymous users => y | |
.. Disallow root login remotely => y | |
.. Remove test database and access to it => y | |
.. Reload privilege tables now => y | |
sudo mysql -u root | |
.. ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY 'mysqlCode'; | |
.. FLUSH PRIVILEGES; | |
.. ctrl +D | |
=> sudo mysql -uroot -pmysqlCode | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment