This article is about building a container package for a React app with Docker and GitHub Actions. The author creates a pipeline in Github Actions to package the React UI code into a container using a Dockerfile and store the package in Amazon ECR.
The pipeline consists of the following stages: checkout react code from Github, generate a random tag to the package, and build the image and push it to Amazon ECR. The author also explains other technologies that will be used in the series, such as containers, Dockerfile, ECS, Fargate, IAM, and so on.
The author creates a React app using a TypeScript template and creates a Dockerfile with specific commands for containerizing the app. The author also adds an .npmrc file temporarily to the Dockerfile to allow the image runtime to pull the package with authorization to the package repository and removes it later.
Then the author builds and tags the image and runs the container using the docker command. The author thinks like a DevOps Engineer and builds a pipeline for reusability, which ensures accuracy in deployments.
The author uses the actions/checkout action to download the code to the GitHub runner and generates a random tag using the date to the package. After that, the author authenticates in AWS and logs in to Amazon ECR. The author then builds the image and pushes it to Amazon ECR.
As a bonus, the author added some logic to identify the latest image in ECR, which is based on the date it was pushed. In the next part of the series, the author intends to explain one of the options to deploy this image in AWS.
The article provides a step-by-step guide on how to containerize a React app using Docker and Github Actions and deploy it in AWS. This tutorial is easily followed and well-detailed, making it a good resource for developers and DevOps engineers alike.