Installations

Ubuntu LAMP

OpenSSH Server

sudo apt-get install openssh-server -y
sudo systemctl enable ssh
sudo systemctl start ssh

Apache

How To Install Linux, Apache, MariaDB, PHP (LAMP) stack on Debian 10

sudo apt install apache2 -y
sudo apache2ctl configtest

sudo ufw app list
sudo ufw app info "Apache Full"
sudo ufw allow in "Apache Full"

Maria DB

sudo apt install mariadb-server -y
sudo mysql_secure_installation
sudo mariadb

PHP

sudo apt install php libapache2-mod-php php-mysql -y

Install AWS Ec2

Tutorial: Install a LAMP web server on Amazon Linux 2

document root settings

sudo usermod -a -G apache ec2-user

sudo chown -R ec2-user:apache /var/www
sudo chmod 2775 /var/www && find /var/www -type d -exec sudo chmod 2775 {} \;
find /var/www -type f -exec sudo chmod 0664 {} \;

## Configure public_html
enable mod usedir
mkdir public_html
chmod 711 ~
chmod 755 ~/public_html

Leave a Reply

Your email address will not be published.