AWS

AWS EC2 Basic Web server setup

Connect to EC2:

ssh -i PEMFILE.PEM ec2-user@publicdnsip4_assigned_by_AWS.com

Update all software:

sudo yum update

Install WEB server:

sudo yum -y install httpd

Start WEB server:

sudo service httpd start

Web server default location:

/var/www/html/

Check WEB server functionality:

Go to /var/www/html

sudo mkdir wwwroot

cd wwwroot

echo “Hello world” >> test.html

Open browser and go to: publicdnsip4_assigned_by_AWS.com/wwwroot/test.html, and magically in the browser you should see : “Hello world”

SCP files from local node to server:

scp -r -i PEMFILE.PEM localdirectory/* ec2-user@publicdnsip4_assigned_by_AWS.com:/var/www/html/wwwroot/

 

This is a very complex way to create hello world in a browser!

Leave a Reply

Back To Top
Bitnami