Last active
November 18, 2024 18:34
-
-
Save zohaibhassan156/abd5d2904b79d22410417ff66b618bbb to your computer and use it in GitHub Desktop.
wsl-settings
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
sudo apt install -y zip unzip | |
#valet linux OS packages | |
sudo apt install -y network-manager libnss3-tools jq xsel | |
#install php | |
sudo add-apt-repository ppa:ondrej/php | |
sudo apt-get install -y php7.3-cli php7.3-curl php7.3-mbstring php7.3-xml php7.3-zip php7.3-gd php7.3-mysql php7.3-pgsql php7.3-sqlite3 php7.3-intl php7.3-bcmath php7.3-mcrypt php7.3-redis php7.3-json | |
sudo apt-get install -y php7.4-cli php7.4-curl php7.4-mbstring php7.4-xml php7.4-zip php7.4-gd php7.4-mysql php7.4-pgsql php7.4-sqlite3 php7.4-intl php7.4-bcmath php7.4-mcrypt php7.4-redis php7.4-json | |
sudo apt-get install -y php8.0-cli php8.0-curl php8.0-mbstring php8.0-xml php8.0-zip php8.0-gd php8.0-mysql php8.0-pgsql php8.0-sqlite3 php8.0-intl php8.0-bcmath php8.0-mcrypt php8.0-redis | |
sudo apt-get install -y php8.1-cli php8.1-curl php8.1-mbstring php8.1-xml php8.1-zip php8.1-gd php8.1-mysql php8.1-pgsql php8.1-sqlite3 php8.1-intl php8.1-bcmath php8.1-mcrypt php8.1-redis | |
sudo apt-get install -y php8.2-cli php8.2-curl php8.2-mbstring php8.2-xml php8.2-zip php8.2-gd php8.2-mysql php8.2-pgsql php8.2-sqlite3 php8.2-intl php8.2-bcmath php8.2-mcrypt php8.2-redis | |
sudo apt-get install -y php8.3-cli php8.3-curl php8.3-mbstring php8.3-xml php8.3-zip php8.3-gd php8.3-mysql php8.3-pgsql php8.3-sqlite3 php8.3-intl php8.3-bcmath php8.3-mcrypt php8.3-redis | |
sudo apt-get install -y php8.4-cli php8.4-curl php8.4-mbstring php8.4-xml php8.4-zip php8.4-gd php8.4-mysql php8.4-pgsql php8.4-sqlite3 php8.4-intl php8.4-bcmath php8.4-mcrypt php8.4-redis | |
================================================================================================================ | |
For Ubuntu, this PPA provides the latest stable upstream Git version | |
sudo add-apt-repository ppa:git-core/ppa | |
sudo apt update; | |
sudo apt install git | |
================================================================================================================ | |
export NVM_DIR="$HOME/.nvm" | |
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm | |
[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" # This loads nvm bash_completion | |
eval `keychain --eval --quiet --noask --agents ssh id_ed25519` | |
================================================================================================================ | |
#Composer | |
https://getcomposer.org/download/ | |
sudo mv composer.phar /usr/local/bin/composer | |
composer global require cpriego/valet-linux | |
composer global require laravel/installer | |
================================================================================================================ | |
#MYSQL 8 Installation | |
sudo apt install mysql-server | |
sudo systemctl start mysql.service | |
ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY ''; | |
#ALTER USER 'root'@'localhost' IDENTIFIED WITH caching_sha2_password BY ''; | |
sudo nano /etc/mysql/my.cnf | |
[mysqld] | |
port = 3306 | |
innodb_buffer_pool_size=4G | |
default_authentication_plugin=mysql_native_password | |
sql_mode = "" | |
=================================================== | |
important innodb server settigs | |
innodb_flush_log_at_trx_commit=1 //change it 2 if ACID compliance not required | |
innodb_buffer_pool_size=8G | |
innodb_io_capacity = 2000 | |
innodb_read_io_threads = 64 | |
innodb_thread_concurrency = 0 | |
innodb_write_io_threads = 64 | |
================================================================================================================ | |
node | |
https://github.com/nvm-sh/nvm | |
================================================================================================================ | |
#Symlinks | |
ln -s /mnt/c/Users/Zohaib/.ssh | |
ln -s /mnt/c/Users/Zohaib/wsl/.bashrc | |
ln -s /mnt/c/Users/Zohaib/wsl/.bash_aliases | |
ln -s /mnt/c/Users/Zohaib/wsl/.gitconfig | |
================================================================================================================ | |
#Common PHP INI Settings | |
sudo gedit /etc/php/8.2/fpm/php.ini | |
max_execution_time | |
memory_limit | |
display_errors | |
display_startup_errors | |
post_max_size | |
upload_max_filesize | |
================================================================================================================ | |
sudo service restart nginx | |
sudo service php(old version)-fpm stop -v | |
sudo service php(new version)-fpm start -v | |
sudo service mysql start |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment