1. ์ธ์คํด์ค ์์ฑ
NGINX Web Server ์ธ์คํด์ค ์์ฑํ๊ธฐ
2. mobaxterm ์ ์
์์ฑํ ์ธ์คํดํธ์ ip์ฃผ์๋ก ์ ๊ทผ
1) instance ip ์ฃผ์ ์ ๋ ฅ
2) Specify username ์ฒดํฌ ํ ec2-user์ ๋ ฅ
3) User private key ์ฒดํฌ ํ key pair์ pem ํ์ผ ๊ฒฝ๋ก ์ง์
์ ์ ์ฑ๊ณต
3. httpd ์ค์น
[ec2-user@ip-10-200-1-184 ~]$ sudo yum -y install httpd
[ec2-user@ip-10-200-1-184 ~]$ sudo systemctl start httpd
[ec2-user@ip-10-200-1-184 ~]$ sudo systemctl status httpd
โ httpd.service - The Apache HTTP Server
Loaded: loaded (/usr/lib/systemd/system/httpd.service; disabled; vendor preset: disabled)
Active: active (running) since Sun 2024-07-07 11:28:31 UTC; 5s ago
Docs: man:httpd.service(8)
Main PID: 9192 (httpd)
Status: "Processing requests..."
CGroup: /system.slice/httpd.service
โโ9192 /usr/sbin/httpd -DFOREGROUND
โโ9193 /usr/sbin/httpd -DFOREGROUND
โโ9194 /usr/sbin/httpd -DFOREGROUND
โโ9195 /usr/sbin/httpd -DFOREGROUND
โโ9196 /usr/sbin/httpd -DFOREGROUND
โโ9197 /usr/sbin/httpd -DFOREGROUND
Jul 07 11:28:31 ip-10-200-1-184.ap-northeast-2.compute.internal systemd[1]: Starting T...
Jul 07 11:28:31 ip-10-200-1-184.ap-northeast-2.compute.internal systemd[1]: Started Th...
Hint: Some lines were ellipsized, use -l to show in full.
[ec2-user@ip-10-200-1-184 ~]$ sudo systemctl enable httpd
Created symlink from /etc/systemd/system/multi-user.target.wants/httpd.service to /usr/lib/systemd/system/httpd.service.
4. root ์ ๊ทผ
[ec2-user@ip-10-200-1-184 ~]$ sudo passwd root
Changing password for user root.
New password:
BAD PASSWORD: The password fails the dictionary check - it is based on a dictionary word
Retype new password:
passwd: all authentication tokens updated successfully.
[ec2-user@ip-10-200-1-184 ~]$ su -
Password:
[root@ip-10-200-1-184 ~]#
5. index.html ์์ฑ
[root@ip-10-200-1-184 ~]# echo 'AWS HTTP test' > /var/www/html/index.html
[root@ip-10-200-1-184 ~]# curl http://54.180.131.165
AWS HTTP test
์ฐธ์กฐ ๋ธ๋ก๊ทธ : https://jindevelopetravel0919.tistory.com/189
1. FQDN ์ ์์ ์ํด ๊ฐ๋น์ ๋๋ฉ์ธ ๊ตฌ์
๋๋ฉ์ธ 500์ ๊ตฌ๋งค
2. Route 53 ํธ์คํ ์์ญ ์์ฑ
3. ๋ ์ฝ๋ ์์ฑ
4. ๊ฐ๋น์ ๋๋ฉ์ธ NS ํธ์ง
๊ธฐ๋ณธ ํธ์คํธ๋ช ์ ์ง์ด ํ ํธ๋ํฝ ๋ผ์ฐํ ๋์ ์ฃผ์๋ก ๋ณ๊ฒฝ
5. ์ผ์ ์๊ฐ ๋๊ธฐ ํ http://minjin.shop์ผ๋ก ์ ์
'AWS' ์นดํ ๊ณ ๋ฆฌ์ ๋ค๋ฅธ ๊ธ
AWS : ALB๋ฅผ ์ด์ฉํ LoadBalancer (0) | 2024.11.07 |
---|---|
AWS : NLB๋ฅผ ์ด์ฉํ LoadBalancer (0) | 2024.11.05 |
AWS : ์์ ํ ํ๋ฆฟ ์์ฑํ๊ธฐ (0) | 2024.11.05 |
AWS : S3 Storage ์์ฑ (0) | 2024.07.08 |
AWS : IAM ์ค์ / VPC ๊ธฐ๋ณธ ์ ํ (0) | 2024.07.05 |