Skip to content

ci: cancel deploy job if didn't touch repo #4

ci: cancel deploy job if didn't touch repo

ci: cancel deploy job if didn't touch repo #4

Workflow file for this run

name: Deploy to DigitalOcean
on:
push:
branches:
- master
jobs:
deploy_mana_prod:
name: Deploy mana to production
environment: mana_prod
concurrency:
group: mana_prod
cancel-in-progress: true
runs-on: ubuntu-latest
steps:
- name: Checkout Repo
uses: actions/checkout@v3
- name: Check for changes
run: git diff-tree --no-commit-id --name-only HEAD -r | grep ^apps/mana || gh run cancel ${{ github.run_id }}
- name: Install doctl
uses: digitalocean/action-doctl@v2
with:
token: ${{ secrets.DIGITALOCEAN_ACCESS_TOKEN }}
- name: Deploy
run: doctl apps create-deployment ${{ vars.DIGITALOCEAN_APP_ID }}