Created
April 26, 2022 14:44
-
-
Save raresteak/10e1e0d80392e945b5f91c3686302578 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
#!/bin/bash | |
# Quick Debian 11 Developer workstation with LAMP | |
# Run after installing Debian 11 | |
if [ $(wget -q http://deb.debian.org/debian) ]; then | |
echo "Built $(date +%Y/%m/%d)" | sudo tee -a /etc/motd | |
echo "vm.swappiness = 1" | sudo tee -a /etc/sysctl.conf | |
sudo sysctl -p | |
sudo apt update | |
sudo apt install -y curl byobu scratch python3-venv python3-pip python3-setuptools python3-wheel build-essential dkms linux-headers-$(uname -r) manpages-dev nmap ncat apache2 apache2-utils mariadb-server php-mysql php libapache2-mod-php php-cli strace ltrace xxd bzip2 shellcheck | |
curl https://packages.microsoft.com/keys/microsoft.asc | sudo apt-key add - | |
sudo sh -c 'echo "deb [arch=amd64] https://packages.microsoft.com/repos/microsoft-debian-bullseye-prod bullseye main" > /etc/apt/sources.list.d/microsoft.list' | |
sudo apt update && sudo apt install -y powershell | |
pwsh -v | |
python3 -V | |
sudo systemctl start mariadb | |
sudo systemctl enable mariadb | |
#sudo mysql_secure_installation | |
sudo mysqladmin version | |
echo "<?php phpinfo(); ?>" | sudo tee -a /var/www/html/aaaa.php | |
sudo systemctl enable apache2 | |
sudo systemctl start apache2 | |
php -v | |
php -m | |
php -l /var/www/html/aaaa.php | |
curl http://127.0.0.1/aaaa.php | |
else | |
echo "Unable to reach the Internet" | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment