WEB DEPLOYMENT ON AMAZON EC2

PREREQUISITE
Before deploying a website on AWS, you must first have an AWS registered account, either as a Root User or as an IAM (Identity Access Management) User.
NOTE: All codes are only compatible to linux operating systems, these codes would not w…


This content originally appeared on DEV Community and was authored by Ovi Eryk

PREREQUISITE
Before deploying a website on AWS, you must first have an AWS registered account, either as a Root User or as an IAM (Identity Access Management) User.
NOTE: All codes are only compatible to linux operating systems, these codes would not work on windows command prompts.

The following are steps you can take after launching an instance on AWS.

STEP 1: Highlight the instance and click the button connect, and it opens a new tab, on the new tab, you will see 'instance connect' option, scroll down and you will see connect. Then it takes you to a command page.

STEP 2: Note that you are connected as an EC2 user, to change that so you can have more control, you key in - sudo su

Image description

STEP 3: You update the server with the code: yum update -y

Image description

STEP 3: After updating, you install the Apache http server with the code: yum install httpd -y

Image description

STEP 4: You then need to create a temporary folder with the code: mkdir temp, and cd temp into it.
Image description

STEP 5: Now, you copy the link of the website you want to deploy and : wget + web link.

Image description

STEP 6: Next you ls into the folder to see the zip folder of the link, and then you unzip with: unzip + file name (the zipped file)

Image description

STEP 7: Do 'ls', then cd into it with: cd + new file. You can also ls to see list of files in the unzipped folder (optional).

Image description

STEP 8: Its now time to move all these files for deployment with: mv * /var/www/html. After that, you cd into it with: cd /var/www/html.

Image description

STEP 9: You are almost ready to deploy, you just need to enable it to work and you do that with: systemctl enable httpd.

Image description

STEP 10: The final step is to start and check the status of the site you are about to deploy. To start: systemctl start httpd
To check status: systemctl status httpd

Image description

YOU ARE READY TO GO!

CONCLUSION:
Voila! You have successfully deployed your website on Amazon EC2. Follow me for more posts like this.


This content originally appeared on DEV Community and was authored by Ovi Eryk


Print Share Comment Cite Upload Translate Updates
APA

Ovi Eryk | Sciencx (2024-10-09T14:20:06+00:00) WEB DEPLOYMENT ON AMAZON EC2. Retrieved from https://www.scien.cx/2024/10/09/web-deployment-on-amazon-ec2/

MLA
" » WEB DEPLOYMENT ON AMAZON EC2." Ovi Eryk | Sciencx - Wednesday October 9, 2024, https://www.scien.cx/2024/10/09/web-deployment-on-amazon-ec2/
HARVARD
Ovi Eryk | Sciencx Wednesday October 9, 2024 » WEB DEPLOYMENT ON AMAZON EC2., viewed ,<https://www.scien.cx/2024/10/09/web-deployment-on-amazon-ec2/>
VANCOUVER
Ovi Eryk | Sciencx - » WEB DEPLOYMENT ON AMAZON EC2. [Internet]. [Accessed ]. Available from: https://www.scien.cx/2024/10/09/web-deployment-on-amazon-ec2/
CHICAGO
" » WEB DEPLOYMENT ON AMAZON EC2." Ovi Eryk | Sciencx - Accessed . https://www.scien.cx/2024/10/09/web-deployment-on-amazon-ec2/
IEEE
" » WEB DEPLOYMENT ON AMAZON EC2." Ovi Eryk | Sciencx [Online]. Available: https://www.scien.cx/2024/10/09/web-deployment-on-amazon-ec2/. [Accessed: ]
rf:citation
» WEB DEPLOYMENT ON AMAZON EC2 | Ovi Eryk | Sciencx | https://www.scien.cx/2024/10/09/web-deployment-on-amazon-ec2/ |

Please log in to upload a file.




There are no updates yet.
Click the Upload button above to add an update.

You must be logged in to translate posts. Please log in or register.