Skip to content

Commit ee68216

Browse files
[feat] update the workflow
1 parent e094264 commit ee68216

1 file changed

Lines changed: 4 additions & 5 deletions

File tree

.github/workflows/main.yml

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,7 @@ jobs:
142142
id: build-image
143143
run: |
144144
IMAGE_TAG=${{ steps.meta.outputs.short_sha }}
145-
ECR_IMAGE=${{ secrets.AWS_ACCOUNT_ID }}.dkr.ecr.${{ secrets.AWS_REGION }}.amazonaws.com/${{ secrets.ECR_REPOSITORY_NAME }}:$IMAGE_TAG
145+
ECR_IMAGE=${{ secrets.ECR_REPOSITORY_URL }}:$IMAGE_TAG
146146
docker build -t $ECR_IMAGE .
147147
echo "ECR_IMAGE=$ECR_IMAGE" >> $GITHUB_ENV
148148
@@ -153,12 +153,11 @@ jobs:
153153
run: |
154154
docker push $ECR_IMAGE
155155
156-
- name: Force new ECS deployment
156+
- name: Deploy to Amazon ECS
157157
# Only run on develop branch (For test purposes). To be replaced with main branch when ready.
158158
if: github.event_name == 'push' && github.ref == 'refs/heads/develop'
159159
run: |
160-
echo "Triggering ECS service update..."
161160
aws ecs update-service \
162161
--cluster ${{ secrets.ECS_CLUSTER_NAME }} \
163-
--force-new-deployment \
164-
--region ${{ secrets.AWS_REGION }}
162+
--service ${{ secrets.ECS_SERVICE_NAME }} \
163+
--force-new-deployment

0 commit comments

Comments
 (0)