Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 20 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,47 +5,67 @@ updates:
schedule:
interval: daily
open-pull-requests-limit: 10
cooldown:
default-days: 7
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "weekly"
cooldown:
default-days: 7
- package-ecosystem: mix
directory: "/apps/api_accounts"
schedule:
interval: daily
open-pull-requests-limit: 10
cooldown:
default-days: 7
- package-ecosystem: mix
directory: "/apps/api_web"
schedule:
interval: daily
open-pull-requests-limit: 10
cooldown:
default-days: 7
- package-ecosystem: mix
directory: "/apps/events"
schedule:
interval: daily
open-pull-requests-limit: 10
cooldown:
default-days: 7
- package-ecosystem: mix
directory: "/apps/fetch"
schedule:
interval: daily
open-pull-requests-limit: 10
cooldown:
default-days: 7
- package-ecosystem: mix
directory: "/apps/health"
schedule:
interval: daily
open-pull-requests-limit: 10
cooldown:
default-days: 7
- package-ecosystem: mix
directory: "/apps/model"
schedule:
interval: daily
open-pull-requests-limit: 10
cooldown:
default-days: 7
- package-ecosystem: mix
directory: "/apps/state"
schedule:
interval: daily
open-pull-requests-limit: 10
cooldown:
default-days: 7
- package-ecosystem: mix
directory: "/apps/state_mediator"
schedule:
interval: daily
open-pull-requests-limit: 10
cooldown:
default-days: 7
16 changes: 14 additions & 2 deletions .github/workflows/asana.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,25 @@ name: Asana integration for GitHub PRs
on:
workflow_dispatch:
pull_request:
types: [review_requested, closed, opened, reopened, converted_to_draft, edited, ready_for_review]
types:
[
review_requested,
closed,
opened,
reopened,
converted_to_draft,
edited,
ready_for_review,
]
pull_request_review:
types: [submitted]

permissions:
pull-requests: read # Needed to read Asana ticket info from PR description

jobs:
call-workflow:
uses: mbta/workflows/.github/workflows/asana.yml@main
uses: mbta/workflows/.github/workflows/asana.yml@c76e5ccd9556fbea52bc41548f7ceed5985ad775 # v5.1.0
with:
development-section: "In Development"
review-section: "Pending Review"
Expand Down
22 changes: 15 additions & 7 deletions .github/workflows/deploy-dev-blue.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,22 @@ name: Deploy to Dev-blue (ECS)

on:
schedule:
- cron: '0 5 * * *'
- cron: "0 5 * * *"
workflow_dispatch:

permissions: {}

concurrency:
group: deploy-dev-blue
cancel-in-progress: true

jobs:
deploy:
name: Deploy
runs-on: ubuntu-latest
permissions:
id-token: write
contents: read
id-token: write # Needed to communicate with AWS
contents: read # Needed to check out code
environment: dev-blue
concurrency: dev-blue
if: github.repository_owner == 'mbta'
Expand All @@ -20,20 +26,22 @@ jobs:
ECS_SERVICE: api-dev-blue

steps:
- uses: actions/checkout@v2
- uses: mbta/actions/build-push-ecr@v2
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
persist-credentials: false
- uses: mbta/actions/build-push-ecr@62db3e5c547c3c7f439c4a7fb98e69fc79c1a9cc # v2.21
id: build-push
with:
role-to-assume: ${{ secrets.AWS_ROLE_ARN }}
docker-repo: ${{ secrets.DOCKER_REPO }}
docker-additional-tags: dev-blue
- uses: mbta/actions/deploy-ecs@v2
- uses: mbta/actions/deploy-ecs@62db3e5c547c3c7f439c4a7fb98e69fc79c1a9cc # v2.21
with:
role-to-assume: ${{ secrets.AWS_ROLE_ARN }}
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
- uses: mbta/actions/notify-slack-deploy@62db3e5c547c3c7f439c4a7fb98e69fc79c1a9cc # v2.21
if: ${{ !cancelled() }}
with:
webhook-url: ${{ secrets.SLACK_WEBHOOK }}
Expand Down
20 changes: 14 additions & 6 deletions .github/workflows/deploy-dev-green.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,34 +2,42 @@ name: Deploy to Dev-green (ECS)

on: workflow_dispatch

permissions: {}

concurrency:
group: deploy-dev-green
cancel-in-progress: true

jobs:
deploy:
name: Deploy
runs-on: ubuntu-latest
permissions:
id-token: write
contents: read
id-token: write # Needed to communicate with AWS
contents: read # Needed to check out code
environment: dev-green
concurrency: dev-green
env:
ECS_CLUSTER: api
ECS_SERVICE: api-dev-green

steps:
- uses: actions/checkout@v2
- uses: mbta/actions/build-push-ecr@v2
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
persist-credentials: false
- uses: mbta/actions/build-push-ecr@62db3e5c547c3c7f439c4a7fb98e69fc79c1a9cc # v2.21
id: build-push
with:
role-to-assume: ${{ secrets.AWS_ROLE_ARN }}
docker-repo: ${{ secrets.DOCKER_REPO }}
docker-additional-tags: dev-green
- uses: mbta/actions/deploy-ecs@v2
- uses: mbta/actions/deploy-ecs@62db3e5c547c3c7f439c4a7fb98e69fc79c1a9cc # v2.21
with:
role-to-assume: ${{ secrets.AWS_ROLE_ARN }}
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
- uses: mbta/actions/notify-slack-deploy@62db3e5c547c3c7f439c4a7fb98e69fc79c1a9cc # v2.21
if: ${{ !cancelled() }}
with:
webhook-url: ${{ secrets.SLACK_WEBHOOK }}
Expand Down
20 changes: 14 additions & 6 deletions .github/workflows/deploy-dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,34 +5,42 @@ on:
push:
branches: [master]

permissions: {}

concurrency:
group: deploy-dev
cancel-in-progress: true

jobs:
deploy:
name: Deploy
runs-on: ubuntu-latest
permissions:
id-token: write
contents: read
id-token: write # Needed to communicate with AWS
contents: read # Needed to check out code
environment: dev
concurrency: dev
env:
ECS_CLUSTER: api
ECS_SERVICE: api-dev

steps:
- uses: actions/checkout@v2
- uses: mbta/actions/build-push-ecr@v2
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
persist-credentials: false
- uses: mbta/actions/build-push-ecr@62db3e5c547c3c7f439c4a7fb98e69fc79c1a9cc # v2.21
id: build-push
with:
role-to-assume: ${{ secrets.AWS_ROLE_ARN }}
docker-repo: ${{ secrets.DOCKER_REPO }}
docker-additional-tags: dev
- uses: mbta/actions/deploy-ecs@v2
- uses: mbta/actions/deploy-ecs@62db3e5c547c3c7f439c4a7fb98e69fc79c1a9cc # v2.21
with:
role-to-assume: ${{ secrets.AWS_ROLE_ARN }}
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
- uses: mbta/actions/notify-slack-deploy@62db3e5c547c3c7f439c4a7fb98e69fc79c1a9cc # v2.21
if: ${{ !cancelled() }}
with:
webhook-url: ${{ secrets.SLACK_WEBHOOK }}
Expand Down
20 changes: 14 additions & 6 deletions .github/workflows/deploy-prod.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,35 +2,43 @@ name: Deploy to Prod (ECS)

on: workflow_dispatch

permissions: {}

concurrency:
group: deploy-prod
cancel-in-progress: true

jobs:
deploy:
name: Deploy
runs-on: ubuntu-latest
permissions:
id-token: write
contents: read
id-token: write # Needed to communicate with AWS
contents: read # Needed to check out code
environment: prod
concurrency: prod
env:
ECS_CLUSTER: api
ECS_SERVICE: api-prod

steps:
- uses: actions/checkout@v2
- uses: mbta/actions/build-push-ecr@v2
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
persist-credentials: false
- uses: mbta/actions/build-push-ecr@62db3e5c547c3c7f439c4a7fb98e69fc79c1a9cc # v2.21
id: build-push
with:
role-to-assume: ${{ secrets.AWS_ROLE_ARN }}
docker-repo: ${{ secrets.DOCKER_REPO }}
docker-additional-tags: prod
- name: Deploy to ECS
uses: mbta/actions/deploy-ecs@v2
uses: mbta/actions/deploy-ecs@62db3e5c547c3c7f439c4a7fb98e69fc79c1a9cc # v2.21
with:
role-to-assume: ${{ secrets.AWS_ROLE_ARN }}
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
- uses: mbta/actions/notify-slack-deploy@62db3e5c547c3c7f439c4a7fb98e69fc79c1a9cc # v2.21
if: ${{ !cancelled() }}
with:
webhook-url: ${{ secrets.SLACK_WEBHOOK }}
Expand Down
14 changes: 12 additions & 2 deletions .github/workflows/docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,20 @@ name: Docker

on: [push]

permissions: {}

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
docker:
name: Build Docker image
runs-on: ubuntu-22.04
permissions:
contents: read # Needed to check out code
steps:
- uses: actions/checkout@v3
- run: docker build .
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
persist-credentials: false
- run: docker build .
Loading
Loading