diff --git a/userdata.sh b/userdata.sh new file mode 100644 index 0000000..db03623 --- /dev/null +++ b/userdata.sh @@ -0,0 +1,8 @@ +#!/bin/bash + +sudo yum update -y +sudo yum install -y httpd +sudo systemctl start httpd +sudo systemctl enable httpd +echo "

Hello World


You successfully deployed your first EC2 instance using Terraform

" | sudo tee /var/www/html/index.html +sudo systemctl restart httpd \ No newline at end of file