Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
sakthi-aot committed Mar 19, 2024
1 parent 46d6306 commit 091b200
Show file tree
Hide file tree
Showing 5 changed files with 135 additions and 5 deletions.
31 changes: 30 additions & 1 deletion .github/workflows/caseflow_core.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,4 +35,33 @@ jobs:
with:
context: ./app/caseflow_core/microservices/server
push: true
tags: ${{ github.event.inputs.ecr }}/${{ github.event.inputs.reponame }}:${{ github.event.inputs.version }}
tags: ${{ github.event.inputs.ecr }}/${{ github.event.inputs.reponame }}:${{ github.event.inputs.version }}


- name: Download ECS Task Definition JSON file from S3
run: |
aws s3 cp s3://caseflow-secrets/caseflow_core-revision16.json ./ecs-task-definition/caseflow_core-revision16.json \
--region ca-central-1
shell: /usr/bin/bash -e {0}
env:
AWS_DEFAULT_REGION: ca-central-1
AWS_REGION: ca-central-1
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}

- name: Fill in the new image ID in the Amazon ECS task definition
id: task-def
uses: aws-actions/amazon-ecs-render-task-definition@v1
with:
task-definition: ./ecs-task-definition/caseflow_core-revision16.json
container-name: caseflow-core
image: ${{ github.event.inputs.ecr }}/${{ github.event.inputs.reponame }}:${{ github.event.inputs.version }}

- name: Deploy Amazon ECS Task Definition
uses: aws-actions/amazon-ecs-deploy-task-definition@v1
with:
task-definition: ${{ steps.task-def.outputs.task-definition }}
service: caseflow-core
cluster: caseflow-microservices
wait-for-service-stability: true
30 changes: 29 additions & 1 deletion .github/workflows/caseflow_gateway.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,4 +35,32 @@ jobs:
with:
context: ./app/caseflow_core/microservices/gateway
push: true
tags: ${{ github.event.inputs.ecr }}/${{ github.event.inputs.reponame }}:${{ github.event.inputs.version }}
tags: ${{ github.event.inputs.ecr }}/${{ github.event.inputs.reponame }}:${{ github.event.inputs.version }}

- name: Download ECS Task Definition JSON file from S3
run: |
aws s3 cp s3://caseflow-secrets/caseflow-gateway-revision5.json ./ecs-task-definition/caseflow-gateway-revision5.json \
--region ca-central-1
shell: /usr/bin/bash -e {0}
env:
AWS_DEFAULT_REGION: ca-central-1
AWS_REGION: ca-central-1
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}

- name: Fill in the new image ID in the Amazon ECS task definition
id: task-def
uses: aws-actions/amazon-ecs-render-task-definition@v1
with:
task-definition: ./ecs-task-definition/caseflow-gateway-revision5.json
container-name: caseflow-gateway
image: ${{ github.event.inputs.ecr }}/${{ github.event.inputs.reponame }}:${{ github.event.inputs.version }}

- name: Deploy Amazon ECS Task Definition
uses: aws-actions/amazon-ecs-deploy-task-definition@v1
with:
task-definition: ${{ steps.task-def.outputs.task-definition }}
service: caseflow-gateway
cluster: caseflow-microservices
wait-for-service-stability: true
35 changes: 34 additions & 1 deletion .github/workflows/caseflow_lob.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,4 +35,37 @@ jobs:
with:
context: ./app/caseflow_core/microservices/lob
push: true
tags: ${{ github.event.inputs.ecr }}/${{ github.event.inputs.reponame }}:${{ github.event.inputs.version }}
tags: ${{ github.event.inputs.ecr }}/${{ github.event.inputs.reponame }}:${{ github.event.inputs.version }}

- name: Download ECS Task Definition JSON file from S3
run: |
aws s3 cp s3://caseflow-secrets/caseflow_lob-revision6.json ./ecs-task-definition/caseflow_lob-revision6.json \
--region ca-central-1
shell: /usr/bin/bash -e {0}
env:
AWS_DEFAULT_REGION: ca-central-1
AWS_REGION: ca-central-1
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}

- name: Fill in the new image ID in the Amazon ECS task definition
id: task-def
uses: aws-actions/amazon-ecs-render-task-definition@v1
with:
task-definition: ./ecs-task-definition/caseflow_lob-revision6.json
container-name: caseflow_lob
image: ${{ github.event.inputs.ecr }}/${{ github.event.inputs.reponame }}:${{ github.event.inputs.version }}

- name: Deploy Amazon ECS Task Definition
uses: aws-actions/amazon-ecs-deploy-task-definition@v1
with:
task-definition: ${{ steps.task-def.outputs.task-definition }}
service: caseflow_lob
cluster: caseflow-microservices
wait-for-service-stability: true





30 changes: 29 additions & 1 deletion .github/workflows/caseflow_microservice.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,4 +35,32 @@ jobs:
with:
context: ./app/caseflow_core/microservices/dms
push: true
tags: ${{ github.event.inputs.ecr }}/${{ github.event.inputs.reponame }}:${{ github.event.inputs.version }}
tags: ${{ github.event.inputs.ecr }}/${{ github.event.inputs.reponame }}:${{ github.event.inputs.version }}

- name: Download ECS Task Definition JSON file from S3
run: |
aws s3 cp s3://caseflow-secrets/caseflow_dms-revision3.json ./ecs-task-definition/caseflow_dms-revision3.json \
--region ca-central-1
shell: /usr/bin/bash -e {0}
env:
AWS_DEFAULT_REGION: ca-central-1
AWS_REGION: ca-central-1
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}

- name: Fill in the new image ID in the Amazon ECS task definition
id: task-def
uses: aws-actions/amazon-ecs-render-task-definition@v1
with:
task-definition: ./ecs-task-definition/caseflow_dms-revision3.json
container-name: caseflow-microservice
image: ${{ github.event.inputs.ecr }}/${{ github.event.inputs.reponame }}:${{ github.event.inputs.version }}

- name: Deploy Amazon ECS Task Definition
uses: aws-actions/amazon-ecs-deploy-task-definition@v1
with:
task-definition: ${{ steps.task-def.outputs.task-definition }}
service: caseflow-dms
cluster: caseflow-microservices
wait-for-service-stability: true
14 changes: 13 additions & 1 deletion .github/workflows/caseflow_web.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,11 +50,23 @@ jobs:
push: true
tags: ${{ github.event.inputs.ecr }}/${{ github.event.inputs.reponame }}:${{ github.event.inputs.version }}

- name: Download ECS Task Definition JSON file from S3
run: |
aws s3 cp s3://caseflow-secrets/caseflow_web-revision148.json ./ecs-task-definition/caseflow_web-revision148.json \
--region ca-central-1
shell: /usr/bin/bash -e {0}
env:
AWS_DEFAULT_REGION: ca-central-1
AWS_REGION: ca-central-1
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}

- name: Fill in the new image ID in the Amazon ECS task definition
id: task-def
uses: aws-actions/amazon-ecs-render-task-definition@v1
with:
task-definition: caseflow_web.json
task-definition: ./ecs-task-definition/caseflow_web-revision148.json
container-name: caseflow_web
image: ${{ github.event.inputs.ecr }}/${{ github.event.inputs.reponame }}:${{ github.event.inputs.version }}

Expand Down

0 comments on commit 091b200

Please sign in to comment.