"Launching First Virtual Server && Web server is Launched using EC2 user data"
◉ Select AMI (Amazon Machine Image) - Amazon Linux 2 AMI - Free tier
◉ Default VPC will be added , No IAM Role is not added
◉ User data script , install httpd - $ yum update -y
yum install -y httpd
systemctl start httpd
systemctl enable httpd
echo "<h1> Hello World from $(hostname -f) </h1>" > /var/www/html/index.html
◉ Add Storage
◉ Add Tags Name : first_instance , Department : Devops
◉ Add Security Group , - SSH - TCP - 22
- HTTP - TCP - 80
◉ Download Key-pair , Review and Launch the EC2 Instance
◉ use public IP address to check in the browser , we can see the hello world
◉ Everytime EC2 instance stops and starts again , Public IP address changes