Skip to content

Deployment Auto-Approver #449

Deployment Auto-Approver

Deployment Auto-Approver #449

name: Deployment Auto-Approver
# using triggers for every deployment and allowed manually
# docs on these triggers:
on:
# allows manually triggering (see https://docs.github.com/en/actions/using-workflows/events-that-trigger-workflows#workflow_dispatch)
workflow_dispatch:
schedule:
# 08:30 UTC daily (see https://docs.github.com/en/actions/using-workflows/events-that-trigger-workflows#schedule)
- cron: "30 08 * * *"
# the only problem with the 'deployment' trigger is that dependabot PRs are considered from forked repos and the token doesn't have permission to approve (see https://docs.github.com/en/actions/using-workflows/events-that-trigger-workflows#deployment)
# deployment:
jobs:
auto_approve:
runs-on: ubuntu-latest
steps:
- name: Auto Approve Deploys
uses: activescott/automate-environment-deployment-approval@main
with:
github_token: ${{ secrets.GH_TOKEN_FOR_AUTO_APPROVING_DEPLOYS }}
environment_allow_list: |
aws
# e.g. "dependabot[bot]"
actor_allow_list: |
dependabot[bot]
activescott