시스템 업데이트
sudo apt update
Apache2 설치
sudo apt install apache2
방화벽 구성
Ubuntu 22.04에는 UFW라는 방화벽이 기본적으로 활성화되어 있다.
방화벽을 통한 HTTP 트래픽을 허용하도록 UFW를 구성해야 한다.
sudo ufw allow http
sudo ufw allow https
active 상태인지 확인
systemctl status apache2
http페이지 확인을 위해 ip주소 얻고 확인하기
ip address
라고 터미널에 입력한다.
PHP
sudo apt install php