You will start by deploying the example application which allows a customer to order medical assistance based on selecting a map location. The application consists of a public AWS API gateway which connects to a serverless application layer AWS Lambda, which uses Amazon DynamoDB .
You will also deploy AWS Amplify to host the static website with CI/CD build-in and Amazon Cognito to manage users.
Our deployed architecture should reflect the following diagram:
Note the following:
AWS Amplify hosts static web resources including HTML, CSS, JavaScript, and image files which are loaded in the user’s browser.
Amazon Cognito provides user management and authentication functions to secure the backend API.
Amazon DynamoDB provides a persistence layer where data can be stored by the API’s Lambda function.
JavaScript executed in the browser sends and receives data from a public backend API built using Lambda and API Gateway.
To deploy the template for the base infrastructure complete the following steps:
For our application deployment, we will use AWS Cloud9 as our IDE, where our prebuilt script will be automatically cloned.
You can get the CloudFormation template here.
If you need detailed instructions on how to deploy CloudFormation stacks from within the console, please follow this guide.
For the stack name use cloud9-stack and click the Next button.
Click Next button.
Scroll down to the bottom of the stack creation page and acknowledge the IAM resources creation by selecting all the check boxes. Then launch the stack. It may take 4-5 minutes to complete this deployment.
Click cloud9-stack and go to the Outputs section of the CloudFormation stack. Then, click Cloud9URL to set up your IDE environment.
cd aws-well-architected-labs/static/wapartners/100_Automating_Serverless_Best_Practices_with_Dashbird/Code/oncall-health-sample-app
bash build_script.sh
END OF SECTION 1