AWS App Runner allows us to run web based applications directly on AWS without managing underlying infrastructure. Services can be deployed by simply connecting a Git repository or specifying a container to run.
Open the AWS console, and browse to the AWS App Runner service and select Create an App Runner service.
For your Repository type, select Source code repository. This will require you to add a connection to GitHub in order for AWS App Runner to deploy your new service. Select Add new. New window to configure GitHub cionnections will be open, and either you can select GitHub app if you already set it before, or you will be promted to install AWS Connector for GitHub. Pick the app\profile you used to create the fork. In the Repository drop down select the name of the fork ld-aws-devops-workshop
.
.
Underneath Deployment trigger, select Automatic in order to automatically redeploy your application whenever a code change is pushed to the main branch of your Github repository, then select Next.
For this example, we are going to specify all the settings for our service manually. This is in order to show the control that AWS App Runner gives you.
npm install
npm run start
3000
On the next step we will provide
my-aws-workshop-app
REACT_APP_LD_CLIENT_ID
, and the value as the LaunchDarkly’s client-side ID (Client-side ID from AWS Test environment)Leave the rest of these settings as defaults, and click Next to continue.
Finally, review your settings and select Create & deploy.
This will take about 1-2 minutes to provision
Once status has moved to “Running”, you can click on the URL listed below Default domain in order to view the actual web application you have just deployed.
Congratulations, you have just deployed a simple web service using App Runner!