AWS Final - (FTP, Apache 구축)
## Instance 엘라스틱 공인 IP를 사용하여, 603호 홈페이지가 보이게 구축하라.
## Instance 공인 IP 확인 및 SSH 접속 ##
## FTP Server 구축 ##
SSH]
rpm -qa | grep vsftpd
yum -y install vsftpd
## 설치가 끝났으면, 시작 ##
systemctl start vsftpd.service
systemctl enable vsftpd.service
// 설정값 변경
vi /etc/vsftpd/vsftpd.conf
cd /var/ftp
ls -al
chown ftp:ftp ./pub
chmod 777 ./pub
ls -al
// 이제 [보아 사진]과 [보아 동영상]을 업로드 하여 Apache 웹서버를 구축하는데 필요한 파일을 업로드하자.


## Apache Web Server 구축 ##
## 아파치 설치 ##
yum -y install httpd*
// 중요파일 backup 디렉토리에 옮기기
mkdir /backup
cp /etc/hosts /etc/resolv.conf /etc/httpd/conf/httpd.conf /backup
// Web Server 설정
cd /var/www/html
ls -al
vi ./index.html
// 아까 FTP를 통해 옮긴 사진과 영상을 index.html이 있는 현재 디렉토리로 copy 해오기.
cp /var/ftp/pub/* ./
ls -al
// 이제 실행을 해주자.
systemctl start httpd.service
systemctl enable httpd.service
// 마지막으로 방화벽 해제!!
yum -y install firewalld
systemctl start firewalld
firewall-cmd --permanent --zone=public --add-port=80/tcp
firewall-cmd --permanent --zone=public --add-port=443/tcp
firewall-cmd --reload (이거 안해줘도 정상적으로 들어가진 사람도 있음 ㅋㅋㅋ;;)