Apache 2.4.18 + PHP-FPM 7.2 + MySQL 5.7(APM)
$apt-get update
$apt-get install apache2 libapache2-mod-fastcgi (아파치 설치)
$apt-get install mysql-server (MySQL 설치)
$apt install python-software-properties
$add-apt-repository ppa:ondrej/php
$apt update
$apt install php7.2 php7.2-fpm
$a2enmod actions fastcgi alias proxy_fcgi
$vim /etc/apache2/sites-available/000-default.conf
ㄴ
<VirtualHost *:80>
ServerName example.com
ServerAlias www.example.com
DocumentRoot /var/www/html
<Directory /var/www/html>
Options -Indexes +FollowSymLinks +MultiViews
AllowOverride All
Require all granted
</Directory>
<FilesMatch \.php$>
# 2.4.10+ can proxy to unix socket
SetHandler "proxy:unix:/var/run/php/php7.2-fpm.sock|fcgi://localhost/"
# Else we can just use a tcp socket:
#SetHandler "proxy:fcgi://127.0.0.1:9000"
</FilesMatch>
ErrorLog ${APACHE_LOG_DIR}/error.log
CustomLog ${APACHE_LOG_DIR}/access.log combined
</VirtualHost>