-
Notifications
You must be signed in to change notification settings - Fork 7
46 lines (44 loc) · 1.58 KB
/
deploy-dev-ecs.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
name: Deploy to Dev (ECS)
on:
workflow_dispatch:
push:
branches: [master]
jobs:
deploy:
name: Deploy
runs-on: ubuntu-latest
environment: dev
concurrency: dev
env:
ECS_CLUSTER: skate
ECS_SERVICE: skate-dev
AWS_DEFAULT_REGION: us-east-1
steps:
- uses: actions/checkout@v3
- uses: mbta/actions/build-push-ecr@v1
id: build-push
with:
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
docker-repo: ${{ secrets.DOCKER_REPO }}
- name: Upload static assets to S3
run: bash upload_assets.sh ${{ steps.build-push.outputs.docker-tag }}
env:
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
AWS_DEFAULT_REGION: ${{ env.AWS_DEFAULT_REGION }}
SENTRY_ORG: ${{ secrets.SENTRY_ORG }}
SENTRY_PROJECT: ${{ secrets.SENTRY_PROJECT }}
SENTRY_AUTH_TOKEN: ${{ secrets.SENTRY_AUTH_TOKEN }}
- uses: mbta/actions/deploy-ecs@v1
with:
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
ecs-cluster: ${{ env.ECS_CLUSTER }}
ecs-service: ${{ env.ECS_SERVICE }}
docker-tag: ${{ steps.build-push.outputs.docker-tag }}
- uses: mbta/actions/notify-slack-deploy@v1
if: ${{ !cancelled() }}
with:
webhook-url: ${{ secrets.SLACK_WEBHOOK }}
job-status: ${{ job.status }}