Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/xsalazar/terraform-aws-docker-deploy
🍳 This repository holds simple boilerplate code to deploy a basic Typescript API application within a Fargate-managed ECS cluster. This repository also leverages GitHub Actions to lay the CI/CD groundwork to automatically deploy application changes to ECR and redeploy the ECS cluster with updates.
https://github.com/xsalazar/terraform-aws-docker-deploy
aws docker ecs fargate github-actions terraform typescript
Last synced: 3 days ago
JSON representation
🍳 This repository holds simple boilerplate code to deploy a basic Typescript API application within a Fargate-managed ECS cluster. This repository also leverages GitHub Actions to lay the CI/CD groundwork to automatically deploy application changes to ECR and redeploy the ECS cluster with updates.
- Host: GitHub
- URL: https://github.com/xsalazar/terraform-aws-docker-deploy
- Owner: xsalazar
- Created: 2021-02-13T22:44:32.000Z (almost 4 years ago)
- Default Branch: main
- Last Pushed: 2024-05-27T23:48:08.000Z (6 months ago)
- Last Synced: 2024-05-28T08:59:04.439Z (6 months ago)
- Topics: aws, docker, ecs, fargate, github-actions, terraform, typescript
- Language: HCL
- Homepage:
- Size: 627 KB
- Stars: 9
- Watchers: 3
- Forks: 5
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- Funding: .github/FUNDING.yml
Awesome Lists containing this project
README
# Terraform/AWS Docker Deploy to Fargate
This repository holds simple boilerplate code to deploy a basic Typescript API application within a Fargate-managed ECS cluster.
This repository also leverages GitHub Actions to lay the CI/CD groundwork to automatically deploy application changes to ECR and redeploy the ECS cluster with updates.## Installation
### Application
The Typescript application code lives in the [`app/`](app/) subdirectory. This application is built using `node` v18.
```bash
cd app/
npm install && npm start
```### Infrastructure
The required `terraform` version for this repository is v1.1.2. The architecture built from this code is below.
![](assets/architecture/architecture.svg)
## Usage
This repository is meant to be managed through GitHub Action as the main CI/CD pipeline.
The initial bootstrapping should be done by running the [bootstrap](.github/workflows/bootstrap.yml) workflow. This will initialize the ECR registry, push the initial Docker image, and then apply the remaining infrastructure, deploying the Docker image to ECS.
Subsequent changes can be applied by running the [push_to_ecr](.github/workflows/push_to_ecr.yml) workflow.