Skip to content

Instantly share code, notes, and snippets.

@suhailroushan13
Last active January 8, 2024 07:36
Show Gist options
  • Save suhailroushan13/043d2d65603b276620487839cacc2354 to your computer and use it in GitHub Desktop.
Save suhailroushan13/043d2d65603b276620487839cacc2354 to your computer and use it in GitHub Desktop.
Get All Packages In Ubuntu
sudo apt update && sudo apt upgrade -y
sudo apt install -y git
sudo apt install net-tools -y
sudo timedatectl set-timezone Asia/Kolkata
sudo apt-get -y install nginx -y
sudo apt install snapd -y
sudo snap install core
sudo apt-get install python3-certbot-nginx -y
sudo snap install --classic certbot
sudo ln -s /snap/bin/certbot /usr/bin/
sudo apt install python3-pip -y
sudo apt-get autoremove -y
sudo apt full-upgrade -y
sudo apt install gcc -y
git config --global user.name "suhailroushan13"
git config --global user.email [email protected]
sudo apt-get update && sudo apt-get install -y ca-certificates curl gnupg
curl -fsSL https://deb.nodesource.com/gpgkey/nodesource-repo.gpg.key | sudo gpg --dearmor -o /etc/apt/keyrings/nodesource.gpg
NODE_MAJOR=20
echo "deb [signed-by=/etc/apt/keyrings/nodesource.gpg] https://deb.nodesource.com/node_$NODE_MAJOR.x nodistro main" | sudo tee /etc/apt/sources.list.d/nodesource.list
sudo apt-get update && sudo apt-get install nodejs -y
sudo npm install npm@latest
sudo apt install unzip -y
sudo npm i -g pm2 -y
curl -fsSL https://pkg.jenkins.io/debian-stable/jenkins.io.key | sudo tee \
/usr/share/keyrings/jenkins-keyring.asc > /dev/null
echo deb [signed-by=/usr/share/keyrings/jenkins-keyring.asc] \
https://pkg.jenkins.io/debian-stable binary/ | sudo tee \
/etc/apt/sources.list.d/jenkins.list > /dev/null
sudo apt-get install fontconfig openjdk-11-jre -y
sudo apt-get update -y
sudo apt-get install jenkins -y
yes "" | sudo add-apt-repository ppa:ubuntu-toolchain-r/test
sudo apt update
sudo apt install build-essential
sudo apt-get install manpages-dev
sudo apt install g++
sudo apt install ruby-full
sudo apt-get install apt-transport-https ca-certificates gnupg
echo "deb [signed-by=/usr/share/keyrings/cloud.google.gpg] https://packages.cloud.google.com/apt cloud-sdk main" | sudo tee -a /etc/apt/sources.list.d/google-cloud-sdk.list
curl https://packages.cloud.google.com/apt/doc/apt-key.gpg | sudo apt-key --keyring /usr/share/keyrings/cloud.google.gpg add -
sudo apt-get update && sudo apt-get install google-cloud-cli
gcloud auth login --no-launch-browser
curl -fsSL https://packages.redis.io/gpg | sudo gpg --dearmor -o /usr/share/keyrings/redis-archive-keyring.gpg
echo "deb [signed-by=/usr/share/keyrings/redis-archive-keyring.gpg] https://packages.redis.io/deb $(lsb_release -cs) main" | sudo tee /etc/apt/sources.list.d/redis.list
sudo apt-get update
sudo apt-get install redis
cd ~bin
sudo touch cc
echo "clear" > cc
sudo chmod 777 cc
echo "Successfully installed clear"
sudo touch ip
echo "sudo ifconfig" > ip
sudo chmod 777 ip
echo "Successfully installed ifconfig"
sudo touch server
echo "sudo python3 -m http.server 8080" > server
sudo chmod 777 server
echo "Successfully installed server"
sudo touch del
echo "sudo rm -rf *" > del
sudo chmod 777 del
echo "Successfully installed del"
sudo touch push
echo "git add ." >> push
echo "git commit -m Files_Added✅" >> push
echo "git push origin master" >> push
sudo chmod 777 push
echo "Successfully installed push"
sudo touch restart
echo "sudo systemctl restart nginx" > restart
sudo chmod 777 restart
echo "Successfully installed restart"
sudo touch run
echo "cd" >> run
echo "cd /home/suhail/scripts" >> run
echo "./gitscript.sh" >> run
sudo chmod 777 run
echo "Successfully installed run"
sudo touch update
echo "sudo apt-get update -y && sudo apt update -y && sudo apt upgrade -y" > update
sudo chmod 777 update
echo "Successfully installed update"
sudo touch check
echo "sudo nginx -t" > check
sudo chmod 777 check
echo "Successfully installed check"
sudo touch ssl
echo "certbot --nginx" > ssl
sudo chmod 777 ssl
echo "Successfully installed ssl"
sudo touch full
echo "sudo chmod 777 *" > full
sudo chmod 777 full
echo "Successfully installed full"
sudo touch five
echo "sudo kill -9 `sudo lsof -t -i:5000`" > five
sudo chmod 777 five
echo "Successfully installed five"
sudo touch three
echo "sudo kill -9 `sudo lsof -t -i:3000`" > three
sudo chmod 777 three
echo "Successfully installed three"
sudo touch bin
echo "cd ~bin" > bin
sudo chmod 777 bin
echo "Successfully installed bin"
sudo touch db
echo "mongo mongodb+srv://suhail:[email protected]/test" > db
sudo chmod 777 db
echo "Successfully installed db"
#Create a file name ignore
# nano ignore
# add this
sudo touch ignore
sudo chmod 777 ignore
echo "touch .gitignore" > ignore
echo "echo 'node_modules' >> .gitignore" > ignore
echo "echo 'config '>> .gitignore" > ignore
echo "Successfully installed .gitignore"
sudo touch request
echo "git add ." > request
echo "git commit -m Files_Added✅" > request
echo "git push origin misc" > request
sudo chmod 777 request
echo "Successfully installed request"
exit
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment