Description
Write program to create a web tier of a cloud application. Follow the steps below: ∙ Create a static website with one or two HTML pages and copy the pages and dependent fles in an Amazon S3 bucket.
• Create a startup script to install Apache server and copy the website fles from S3 to the instance.
• Create a Python program using boto to launch an t2.micro instance. Supply the startup script you created in previous step while launching a new instance from the program. Use a security group with port 80 open.
• Your program should check the status of the newly launched instance and return the public DNS address of the instance when the status changes to “running’. ∙ Open the public DNS of the newly launched instance in a browser and verify if the static website works.
N.B:
1. You need to install boto in your Laptop. You can install boto from source or using pip command. For installation and boto configuration, you can follow the links below. ∙ https://www.linuxnix.com/python-boto-how-to-install-and-configure-in-linuxunix/ ∙ http://docs.pythonboto.org/en/latest/boto_config_tut.html
2. Tutorial link: http://boto.cloudhackers.com/en/latest/index.html ;
http://boto.cloudhackers.com/en/latest/ref/ec2.html