{"id":3573,"date":"2023-02-06T18:02:23","date_gmt":"2023-02-06T18:02:23","guid":{"rendered":"https:\/\/exceedthecloud.com\/?p=3573"},"modified":"2023-02-11T11:38:13","modified_gmt":"2023-02-11T11:38:13","slug":"how-to-host-a-website-on-an-ec2-instance","status":"publish","type":"post","link":"https:\/\/exceedthecloud.com\/?p=3573","title":{"rendered":"How to Host a Website on an EC2 Instance"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">In this lab, you will host your first website on an EC2 instance. You will be using all the notions from previous labs to complete this lab successfully.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Prerequisite: Having a valid AWS Account (Follow the step in this link to create an AWS Account) <a href=\"https:\/\/exceedthecloud.com\/?p=3419\" target=\"_blank\" rel=\"noreferrer noopener\">How to Sign Up for a new Amazon Web Services Account<\/a><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Open the page: <a href=\"https:\/\/aws.amazon.com\/account\/\" target=\"_blank\" rel=\"noreferrer noopener\">https:\/\/aws.amazon.com\/account\/<\/a><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Create a security group to allow only port 80 and 22 to your EC2 instance<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Type VPC in the search box<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"624\" height=\"473\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture1-7.png\" alt=\"\" class=\"wp-image-3574\" srcset=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture1-7.png 624w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture1-7-300x227.png 300w\" sizes=\"auto, (max-width: 624px) 100vw, 624px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">Select Security groups under Security menu<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"624\" height=\"477\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture2-7.png\" alt=\"\" class=\"wp-image-3575\" srcset=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture2-7.png 624w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture2-7-300x229.png 300w\" sizes=\"auto, (max-width: 624px) 100vw, 624px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">Click on Create Security Group<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"624\" height=\"86\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture3-7.png\" alt=\"\" class=\"wp-image-3576\" srcset=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture3-7.png 624w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture3-7-300x41.png 300w\" sizes=\"auto, (max-width: 624px) 100vw, 624px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">Enter the Security group name<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Add the rule for SSH and HTTP in the inbound rules \/ Click Create security group<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">SSH allowed only from my IP address and HTTP from anywhere<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"624\" height=\"402\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture4-7.png\" alt=\"\" class=\"wp-image-3577\" srcset=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture4-7.png 624w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture4-7-300x193.png 300w\" sizes=\"auto, (max-width: 624px) 100vw, 624px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">Launch our EC2 instance<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Type EC2 in the search box<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"624\" height=\"551\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture5-6.png\" alt=\"\" class=\"wp-image-3578\" srcset=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture5-6.png 624w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture5-6-300x265.png 300w\" sizes=\"auto, (max-width: 624px) 100vw, 624px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">Click on Launch instance<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"624\" height=\"484\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture6-6.png\" alt=\"\" class=\"wp-image-3579\" srcset=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture6-6.png 624w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture6-6-300x233.png 300w\" sizes=\"auto, (max-width: 624px) 100vw, 624px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">Enter your instance name \/ Select Amazon Machine Image \/ Instance type \/ Key pair \/ Security group and storage \/ review and click on Launch instance<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"624\" height=\"462\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture7-6.png\" alt=\"\" class=\"wp-image-3580\" srcset=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture7-6.png 624w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture7-6-300x222.png 300w\" sizes=\"auto, (max-width: 624px) 100vw, 624px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">Confirm that the instance is up and running <\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Note the public IPv4 address, you will need it for the next task<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"624\" height=\"320\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture8-5.png\" alt=\"\" class=\"wp-image-3581\" srcset=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture8-5.png 624w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture8-5-300x154.png 300w\" sizes=\"auto, (max-width: 624px) 100vw, 624px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\"><a href=\"https:\/\/exceedthecloud.com\/?p=3550\" target=\"_blank\" rel=\"noreferrer noopener\">Connect to your EC2 instance with SSH client PuTTY<\/a><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>ec2-user@X.X.X.X(your IP v4 address)<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Enter the IP and Key pair in PuTTY client \/ Click Open<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"449\" height=\"436\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture9-5.png\" alt=\"\" class=\"wp-image-3582\" srcset=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture9-5.png 449w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture9-5-300x291.png 300w\" sizes=\"auto, (max-width: 449px) 100vw, 449px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">Click on Yes to add the key to PuTTY&#8217;s cache and trust the host<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"624\" height=\"362\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture10-5.png\" alt=\"\" class=\"wp-image-3583\" srcset=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture10-5.png 624w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture10-5-300x174.png 300w\" sizes=\"auto, (max-width: 624px) 100vw, 624px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">Confirm you are connected to the EC2 instance with SSH<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"624\" height=\"395\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture11-5.png\" alt=\"\" class=\"wp-image-3584\" srcset=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture11-5.png 624w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture11-5-300x190.png 300w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture11-5-80x50.png 80w\" sizes=\"auto, (max-width: 624px) 100vw, 624px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">Install all the software needed by our website<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Run the commands bellow<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>sudo su\nyum update -y\nyum install -y httpd\ncd \/var\/www\/html\nwget https:\/\/github.com\/marcelin-ndjila\/webtemplate\/archive\/refs\/heads\/main.zip\nunzip main.zip\ncp -r webtemplate-main\/* \/var\/www\/html\nrm -rf webtemplate-main main.zip\nsystemctl enable httpd\nsystemctl start httpd\n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Confirm your have access to the new website by entering the public IP address of your EC2 instance in a browser<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"624\" height=\"326\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture12-3.png\" alt=\"\" class=\"wp-image-3585\" srcset=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture12-3.png 624w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture12-3-300x157.png 300w\" sizes=\"auto, (max-width: 624px) 100vw, 624px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">Clean up your lab and terminate your EC2 instance<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Type and select EC2 in the search bar<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"624\" height=\"556\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture13-2.png\" alt=\"\" class=\"wp-image-3586\" srcset=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture13-2.png 624w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture13-2-300x267.png 300w\" sizes=\"auto, (max-width: 624px) 100vw, 624px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">Select Instances in the menu<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"624\" height=\"417\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture14-3.png\" alt=\"\" class=\"wp-image-3588\" srcset=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture14-3.png 624w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture14-3-300x200.png 300w\" sizes=\"auto, (max-width: 624px) 100vw, 624px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">Select the instance and click on terminate instance<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"624\" height=\"320\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture15-2.png\" alt=\"\" class=\"wp-image-3589\" srcset=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture15-2.png 624w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture15-2-300x154.png 300w\" sizes=\"auto, (max-width: 624px) 100vw, 624px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">Click on Terminate<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"537\" height=\"294\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture16-1.png\" alt=\"\" class=\"wp-image-3590\" srcset=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture16-1.png 537w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture16-1-300x164.png 300w\" sizes=\"auto, (max-width: 537px) 100vw, 537px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">Confirm the instance is terminated<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"624\" height=\"100\" src=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture17-1.png\" alt=\"\" class=\"wp-image-3591\" srcset=\"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture17-1.png 624w, https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/Picture17-1-300x48.png 300w\" sizes=\"auto, (max-width: 624px) 100vw, 624px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">Credit: <em><a href=\"https:\/\/www.aosnote.com\/\" target=\"_blank\" rel=\"noreferrer noopener\">Azeez<\/a><\/em><\/p>\n","protected":false},"excerpt":{"rendered":"<p>In this lab, you will host your first website on an EC2 instance. You will be using all the notions from previous labs to complete this lab successfully. Prerequisite: Having a valid AWS Account (Follow the step in this link &hellip; <a href=\"https:\/\/exceedthecloud.com\/?p=3573\">Continued<\/a><\/p>\n","protected":false},"author":1,"featured_media":3592,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"om_disable_all_campaigns":false,"kt_blocks_editor_width":"","_monsterinsights_skip_tracking":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[121,118,123,26],"tags":[119,120,130,131],"class_list":["post-3573","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-amazon-web-services","category-aws","category-aws-basics","category-web","tag-aws","tag-aws-account","tag-ec2","tag-website"],"aioseo_notices":[],"aioseo_head":"\n\t\t<!-- All in One SEO 5.0.0.1 - aioseo.com -->\n\t<meta name=\"description\" content=\"In this lab, you will host your first website on an EC2 instance. You will be using all the notions from previous labs to complete this lab successfully. Prerequisite: Having a valid AWS Account (Follow the step in this link to create an AWS Account) How to Sign Up for a new Amazon Web Services\" \/>\n\t<meta name=\"robots\" content=\"max-image-preview:large\" \/>\n\t<meta name=\"author\" content=\"Marcelin NDJILA\"\/>\n\t<link rel=\"canonical\" href=\"https:\/\/exceedthecloud.com\/?p=3573\" \/>\n\t<meta name=\"generator\" content=\"All in One SEO (AIOSEO) 5.0.0.1\" \/>\n\t\t<meta property=\"og:locale\" content=\"en_US\" \/>\n\t\t<meta property=\"og:site_name\" content=\"exceedthecloud.com - Going beyond the cloud, learning new stuffs everyday !\" \/>\n\t\t<meta property=\"og:type\" content=\"article\" \/>\n\t\t<meta property=\"og:title\" content=\"How to Host a Website on an EC2 Instance - exceedthecloud.com\" \/>\n\t\t<meta property=\"og:description\" content=\"In this lab, you will host your first website on an EC2 instance. You will be using all the notions from previous labs to complete this lab successfully. Prerequisite: Having a valid AWS Account (Follow the step in this link to create an AWS Account) How to Sign Up for a new Amazon Web Services\" \/>\n\t\t<meta property=\"og:url\" content=\"https:\/\/exceedthecloud.com\/?p=3573\" \/>\n\t\t<meta property=\"article:published_time\" content=\"2023-02-06T18:02:23+00:00\" \/>\n\t\t<meta property=\"article:modified_time\" content=\"2023-02-11T11:38:13+00:00\" \/>\n\t\t<meta name=\"twitter:card\" content=\"summary\" \/>\n\t\t<meta name=\"twitter:title\" content=\"How to Host a Website on an EC2 Instance - exceedthecloud.com\" \/>\n\t\t<meta name=\"twitter:description\" content=\"In this lab, you will host your first website on an EC2 instance. You will be using all the notions from previous labs to complete this lab successfully. Prerequisite: Having a valid AWS Account (Follow the step in this link to create an AWS Account) How to Sign Up for a new Amazon Web Services\" \/>\n\t\t<script type=\"application\/ld+json\" class=\"aioseo-schema\">\n\t\t\t{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"BlogPosting\",\"@id\":\"https:\\\/\\\/exceedthecloud.com\\\/?p=3573#blogposting\",\"name\":\"How to Host a Website on an EC2 Instance - exceedthecloud.com\",\"headline\":\"How to Host a Website on an EC2 Instance\",\"author\":{\"@id\":\"https:\\\/\\\/exceedthecloud.com\\\/?author=1#author\"},\"publisher\":{\"@id\":\"https:\\\/\\\/exceedthecloud.com\\\/#organization\"},\"image\":{\"@type\":\"ImageObject\",\"url\":\"https:\\\/\\\/exceedthecloud.com\\\/wp-content\\\/uploads\\\/2023\\\/02\\\/hosting1.jpg\",\"width\":509,\"height\":339,\"caption\":\"Cloud computing technology concept with 3d rendering cloud with digital connection\"},\"datePublished\":\"2023-02-06T18:02:23+00:00\",\"dateModified\":\"2023-02-11T11:38:13+00:00\",\"inLanguage\":\"en-US\",\"commentCount\":1,\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/exceedthecloud.com\\\/?p=3573#webpage\"},\"isPartOf\":{\"@id\":\"https:\\\/\\\/exceedthecloud.com\\\/?p=3573#webpage\"},\"articleSection\":\"Amazon Web Services, AWS, AWS Basics, Web, AWS, AWS Account, EC2, Website\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/exceedthecloud.com\\\/?p=3573#breadcrumblist\",\"itemListElement\":[{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/exceedthecloud.com#listItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/exceedthecloud.com\",\"nextItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/exceedthecloud.com\\\/?cat=26#listItem\",\"name\":\"Web\"}},{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/exceedthecloud.com\\\/?cat=26#listItem\",\"position\":2,\"name\":\"Web\",\"item\":\"https:\\\/\\\/exceedthecloud.com\\\/?cat=26\",\"nextItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/exceedthecloud.com\\\/?p=3573#listItem\",\"name\":\"How to Host a Website on an EC2 Instance\"},\"previousItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/exceedthecloud.com#listItem\",\"name\":\"Home\"}},{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/exceedthecloud.com\\\/?p=3573#listItem\",\"position\":3,\"name\":\"How to Host a Website on an EC2 Instance\",\"previousItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/exceedthecloud.com\\\/?cat=26#listItem\",\"name\":\"Web\"}}]},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/exceedthecloud.com\\\/#organization\",\"name\":\"exceedthecloud.com\",\"description\":\"Going beyond the cloud, learning new stuffs everyday !\",\"url\":\"https:\\\/\\\/exceedthecloud.com\\\/\"},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/exceedthecloud.com\\\/?author=1#author\",\"url\":\"https:\\\/\\\/exceedthecloud.com\\\/?author=1\",\"name\":\"Marcelin NDJILA\",\"image\":{\"@type\":\"ImageObject\",\"@id\":\"https:\\\/\\\/exceedthecloud.com\\\/?p=3573#authorImage\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/313fe81244bf3b0904f504f4f7306bd513918093551c74d1201a23374c87e9b2?s=96&d=mm&r=g\",\"width\":96,\"height\":96,\"caption\":\"Marcelin NDJILA\"}},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/exceedthecloud.com\\\/?p=3573#webpage\",\"url\":\"https:\\\/\\\/exceedthecloud.com\\\/?p=3573\",\"name\":\"How to Host a Website on an EC2 Instance - exceedthecloud.com\",\"description\":\"In this lab, you will host your first website on an EC2 instance. You will be using all the notions from previous labs to complete this lab successfully. Prerequisite: Having a valid AWS Account (Follow the step in this link to create an AWS Account) How to Sign Up for a new Amazon Web Services\",\"inLanguage\":\"en-US\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/exceedthecloud.com\\\/#website\"},\"breadcrumb\":{\"@id\":\"https:\\\/\\\/exceedthecloud.com\\\/?p=3573#breadcrumblist\"},\"author\":{\"@id\":\"https:\\\/\\\/exceedthecloud.com\\\/?author=1#author\"},\"creator\":{\"@id\":\"https:\\\/\\\/exceedthecloud.com\\\/?author=1#author\"},\"image\":{\"@type\":\"ImageObject\",\"url\":\"https:\\\/\\\/exceedthecloud.com\\\/wp-content\\\/uploads\\\/2023\\\/02\\\/hosting1.jpg\",\"@id\":\"https:\\\/\\\/exceedthecloud.com\\\/?p=3573\\\/#mainImage\",\"width\":509,\"height\":339,\"caption\":\"Cloud computing technology concept with 3d rendering cloud with digital connection\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/exceedthecloud.com\\\/?p=3573#mainImage\"},\"datePublished\":\"2023-02-06T18:02:23+00:00\",\"dateModified\":\"2023-02-11T11:38:13+00:00\"},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/exceedthecloud.com\\\/#website\",\"url\":\"https:\\\/\\\/exceedthecloud.com\\\/\",\"name\":\"exceedthecloud.com\",\"description\":\"Going beyond the cloud, learning new stuffs everyday !\",\"inLanguage\":\"en-US\",\"publisher\":{\"@id\":\"https:\\\/\\\/exceedthecloud.com\\\/#organization\"}}]}\n\t\t<\/script>\n\t\t<!-- All in One SEO -->\n\n","aioseo_head_json":{"title":"How to Host a Website on an EC2 Instance - exceedthecloud.com","description":"In this lab, you will host your first website on an EC2 instance. You will be using all the notions from previous labs to complete this lab successfully. Prerequisite: Having a valid AWS Account (Follow the step in this link to create an AWS Account) How to Sign Up for a new Amazon Web Services","canonical_url":"https:\/\/exceedthecloud.com\/?p=3573","robots":"max-image-preview:large","keywords":"","webmasterTools":{"miscellaneous":""},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"BlogPosting","@id":"https:\/\/exceedthecloud.com\/?p=3573#blogposting","name":"How to Host a Website on an EC2 Instance - exceedthecloud.com","headline":"How to Host a Website on an EC2 Instance","author":{"@id":"https:\/\/exceedthecloud.com\/?author=1#author"},"publisher":{"@id":"https:\/\/exceedthecloud.com\/#organization"},"image":{"@type":"ImageObject","url":"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/hosting1.jpg","width":509,"height":339,"caption":"Cloud computing technology concept with 3d rendering cloud with digital connection"},"datePublished":"2023-02-06T18:02:23+00:00","dateModified":"2023-02-11T11:38:13+00:00","inLanguage":"en-US","commentCount":1,"mainEntityOfPage":{"@id":"https:\/\/exceedthecloud.com\/?p=3573#webpage"},"isPartOf":{"@id":"https:\/\/exceedthecloud.com\/?p=3573#webpage"},"articleSection":"Amazon Web Services, AWS, AWS Basics, Web, AWS, AWS Account, EC2, Website"},{"@type":"BreadcrumbList","@id":"https:\/\/exceedthecloud.com\/?p=3573#breadcrumblist","itemListElement":[{"@type":"ListItem","@id":"https:\/\/exceedthecloud.com#listItem","position":1,"name":"Home","item":"https:\/\/exceedthecloud.com","nextItem":{"@type":"ListItem","@id":"https:\/\/exceedthecloud.com\/?cat=26#listItem","name":"Web"}},{"@type":"ListItem","@id":"https:\/\/exceedthecloud.com\/?cat=26#listItem","position":2,"name":"Web","item":"https:\/\/exceedthecloud.com\/?cat=26","nextItem":{"@type":"ListItem","@id":"https:\/\/exceedthecloud.com\/?p=3573#listItem","name":"How to Host a Website on an EC2 Instance"},"previousItem":{"@type":"ListItem","@id":"https:\/\/exceedthecloud.com#listItem","name":"Home"}},{"@type":"ListItem","@id":"https:\/\/exceedthecloud.com\/?p=3573#listItem","position":3,"name":"How to Host a Website on an EC2 Instance","previousItem":{"@type":"ListItem","@id":"https:\/\/exceedthecloud.com\/?cat=26#listItem","name":"Web"}}]},{"@type":"Organization","@id":"https:\/\/exceedthecloud.com\/#organization","name":"exceedthecloud.com","description":"Going beyond the cloud, learning new stuffs everyday !","url":"https:\/\/exceedthecloud.com\/"},{"@type":"Person","@id":"https:\/\/exceedthecloud.com\/?author=1#author","url":"https:\/\/exceedthecloud.com\/?author=1","name":"Marcelin NDJILA","image":{"@type":"ImageObject","@id":"https:\/\/exceedthecloud.com\/?p=3573#authorImage","url":"https:\/\/secure.gravatar.com\/avatar\/313fe81244bf3b0904f504f4f7306bd513918093551c74d1201a23374c87e9b2?s=96&d=mm&r=g","width":96,"height":96,"caption":"Marcelin NDJILA"}},{"@type":"WebPage","@id":"https:\/\/exceedthecloud.com\/?p=3573#webpage","url":"https:\/\/exceedthecloud.com\/?p=3573","name":"How to Host a Website on an EC2 Instance - exceedthecloud.com","description":"In this lab, you will host your first website on an EC2 instance. You will be using all the notions from previous labs to complete this lab successfully. Prerequisite: Having a valid AWS Account (Follow the step in this link to create an AWS Account) How to Sign Up for a new Amazon Web Services","inLanguage":"en-US","isPartOf":{"@id":"https:\/\/exceedthecloud.com\/#website"},"breadcrumb":{"@id":"https:\/\/exceedthecloud.com\/?p=3573#breadcrumblist"},"author":{"@id":"https:\/\/exceedthecloud.com\/?author=1#author"},"creator":{"@id":"https:\/\/exceedthecloud.com\/?author=1#author"},"image":{"@type":"ImageObject","url":"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/hosting1.jpg","@id":"https:\/\/exceedthecloud.com\/?p=3573\/#mainImage","width":509,"height":339,"caption":"Cloud computing technology concept with 3d rendering cloud with digital connection"},"primaryImageOfPage":{"@id":"https:\/\/exceedthecloud.com\/?p=3573#mainImage"},"datePublished":"2023-02-06T18:02:23+00:00","dateModified":"2023-02-11T11:38:13+00:00"},{"@type":"WebSite","@id":"https:\/\/exceedthecloud.com\/#website","url":"https:\/\/exceedthecloud.com\/","name":"exceedthecloud.com","description":"Going beyond the cloud, learning new stuffs everyday !","inLanguage":"en-US","publisher":{"@id":"https:\/\/exceedthecloud.com\/#organization"}}]},"og:locale":"en_US","og:site_name":"exceedthecloud.com - Going beyond the cloud, learning new stuffs everyday !","og:type":"article","og:title":"How to Host a Website on an EC2 Instance - exceedthecloud.com","og:description":"In this lab, you will host your first website on an EC2 instance. You will be using all the notions from previous labs to complete this lab successfully. Prerequisite: Having a valid AWS Account (Follow the step in this link to create an AWS Account) How to Sign Up for a new Amazon Web Services","og:url":"https:\/\/exceedthecloud.com\/?p=3573","article:published_time":"2023-02-06T18:02:23+00:00","article:modified_time":"2023-02-11T11:38:13+00:00","twitter:card":"summary","twitter:title":"How to Host a Website on an EC2 Instance - exceedthecloud.com","twitter:description":"In this lab, you will host your first website on an EC2 instance. You will be using all the notions from previous labs to complete this lab successfully. Prerequisite: Having a valid AWS Account (Follow the step in this link to create an AWS Account) How to Sign Up for a new Amazon Web Services"},"aioseo_meta_data":{"post_id":"3573","title":null,"description":null,"keywords":[],"keyphrases":{"focus":{"keyphrase":"","score":0,"analysis":{"keyphraseInTitle":{"score":0,"maxScore":9,"error":1}}},"additional":[]},"primary_term":null,"canonical_url":null,"og_title":null,"og_description":null,"og_object_type":"default","og_image_type":"default","og_image_url":null,"og_image_width":null,"og_image_height":null,"og_image_custom_url":null,"og_image_custom_fields":null,"og_video":"","og_custom_url":null,"og_article_section":null,"og_article_tags":[],"twitter_use_og":false,"twitter_card":"default","twitter_image_type":"default","twitter_image_url":null,"twitter_image_custom_url":null,"twitter_image_custom_fields":null,"twitter_title":null,"twitter_description":null,"schema":{"blockGraphs":[],"customGraphs":[],"default":{"data":{"Article":{"id":"#aioseo-article-646bc1144a91f","slug":"article","graphName":"Article","label":"Article","properties":{"type":"BlogPosting","name":"#post_title","headline":"#post_title","description":"#post_excerpt","image":"","keywords":"","author":{"name":"#author_name","url":"#author_url"},"dates":{"include":true,"datePublished":"","dateModified":""}}},"Course":[],"Dataset":[],"FAQPage":[],"Movie":[],"Person":[],"Product":[],"ProductReview":[],"Car":[],"Recipe":[],"Service":[],"SoftwareApplication":[],"WebPage":[]},"graphName":"Article","isEnabled":true},"graphs":[]},"schema_type":"default","schema_type_options":"{\"article\":{\"articleType\":\"BlogPosting\"},\"course\":{\"name\":\"\",\"description\":\"\",\"provider\":\"\"},\"faq\":{\"pages\":[]},\"product\":{\"reviews\":[]},\"recipe\":{\"ingredients\":[],\"instructions\":[],\"keywords\":[]},\"software\":{\"reviews\":[],\"operatingSystems\":[]},\"webPage\":{\"webPageType\":\"WebPage\"}}","pillar_content":false,"robots_default":true,"robots_noindex":false,"robots_noarchive":false,"robots_nosnippet":false,"robots_nofollow":false,"robots_noimageindex":false,"robots_noodp":false,"robots_notranslate":false,"robots_max_snippet":"-1","robots_max_videopreview":"-1","robots_max_imagepreview":"large","priority":null,"frequency":"default","local_seo":null,"breadcrumb_settings":null,"limit_modified_date":false,"ai":null,"created":"2023-02-06 18:02:29","updated":"2025-09-03 00:49:42","seo_analyzer_scan_date":null,"focus_keyword":null,"additional_keywords":null,"truseo_locale":null},"aioseo_breadcrumb":"<div class=\"aioseo-breadcrumbs\"><span class=\"aioseo-breadcrumb\">\n\t\t\t<a href=\"https:\/\/exceedthecloud.com\" title=\"Home\">Home<\/a>\n\t\t<\/span><span class=\"aioseo-breadcrumb-separator\">&raquo;<\/span><span class=\"aioseo-breadcrumb\">\n\t\t\t<a href=\"https:\/\/exceedthecloud.com\/?cat=26\" title=\"Web\">Web<\/a>\n\t\t<\/span><span class=\"aioseo-breadcrumb-separator\">&raquo;<\/span><span class=\"aioseo-breadcrumb\">\n\t\t\tHow to Host a Website on an EC2 Instance\n\t\t<\/span><\/div>","aioseo_breadcrumb_json":[{"label":"Home","link":"https:\/\/exceedthecloud.com"},{"label":"Web","link":"https:\/\/exceedthecloud.com\/?cat=26"},{"label":"How to Host a Website on an EC2 Instance","link":"https:\/\/exceedthecloud.com\/?p=3573"}],"jetpack_featured_media_url":"https:\/\/exceedthecloud.com\/wp-content\/uploads\/2023\/02\/hosting1.jpg","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/exceedthecloud.com\/index.php?rest_route=\/wp\/v2\/posts\/3573","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/exceedthecloud.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/exceedthecloud.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/exceedthecloud.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/exceedthecloud.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=3573"}],"version-history":[{"count":10,"href":"https:\/\/exceedthecloud.com\/index.php?rest_route=\/wp\/v2\/posts\/3573\/revisions"}],"predecessor-version":[{"id":3714,"href":"https:\/\/exceedthecloud.com\/index.php?rest_route=\/wp\/v2\/posts\/3573\/revisions\/3714"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/exceedthecloud.com\/index.php?rest_route=\/wp\/v2\/media\/3592"}],"wp:attachment":[{"href":"https:\/\/exceedthecloud.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=3573"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/exceedthecloud.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=3573"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/exceedthecloud.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=3573"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}