diff --git a/.github/workflows/ci-app.yml b/.github/workflows/ci-app.yml index 6d585aec..1167c198 100644 --- a/.github/workflows/ci-app.yml +++ b/.github/workflows/ci-app.yml @@ -85,6 +85,11 @@ jobs: steps: - uses: actions/checkout@v3 + - name: Set up QEMU + uses: docker/setup-qemu-action@v2 + with: + platforms: arm64 + - name: Setup Docker Buildx uses: docker/setup-buildx-action@v2 @@ -92,6 +97,7 @@ jobs: uses: docker/build-push-action@v3 with: context: src + platforms: linux/arm64 cache-from: type=gha cache-to: type=gha,mode=max diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 786d3f09..f90dbf09 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -145,6 +145,11 @@ jobs: id: date run: echo "timestamp=$(date +'%Y-%m-%d_%H-%M-%S')" >> $GITHUB_OUTPUT + - name: Set up QEMU + uses: docker/setup-qemu-action@v2 + with: + platforms: arm64 + - name: Setup Docker Buildx uses: docker/setup-buildx-action@v2 @@ -156,6 +161,7 @@ jobs: uses: docker/build-push-action@v3 with: context: src + platforms: linux/arm64 push: true tags: ${{ env.ECR_REGISTRY }}/${{ env.ECR_REPO}}:${{ env.IMAGE_TAG }} cache-from: type=gha diff --git a/terraform-iac/modules/app/main.tf b/terraform-iac/modules/app/main.tf index 9da48eeb..296543ce 100644 --- a/terraform-iac/modules/app/main.tf +++ b/terraform-iac/modules/app/main.tf @@ -36,7 +36,7 @@ module "acs" { } module "my_fargate_api" { - source = "github.com/byu-oit/terraform-aws-fargate-api?ref=v4.0.1" + source = "github.com/byu-oit/terraform-aws-fargate-api?ref=v5.0.0" app_name = "${local.name}-${var.env}" container_port = 8080 health_check_path = "/health" @@ -55,6 +55,8 @@ module "my_fargate_api" { role_permissions_boundary_arn = module.acs.role_permissions_boundary.arn log_retention_in_days = var.log_retention_days + cpu_architecture = "ARM64" + primary_container_definition = { name = "${local.name}-${var.env}" image = "${data.aws_ecr_repository.my_ecr_repo.repository_url}:${var.image_tag}"