Skip to content

Cleanup Deployment #179

Cleanup Deployment

Cleanup Deployment #179

Workflow file for this run

name: Cleanup Deployment
concurrency:
group: no-group
cancel-in-progress: true
on:
schedule:
- cron: '0 1 * * *'
jobs:
cleanup-deployments:
runs-on: ubuntu-latest
permissions: write-all
steps:
- name: 🗑 Delete deployment
uses: strumwolf/delete-deployment-environment@v2
with:
token: ${{ secrets.GITHUB_TOKEN }}
environment: github-pages
onlyRemoveDeployments: true
cleanup-releases:
runs-on: ubuntu-latest
permissions: write-all
steps:
- uses: dev-drprasad/[email protected]
with:
repo: <owner>/<repoName> # defaults to current repo
keep_latest: 3
keep_min_download_counts: 1
delete_expired_data: 10
delete_tag_pattern: beta
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
del_runs:
runs-on: ubuntu-latest
permissions:
actions: write
contents: read
steps:
- name: Delete workflow runs
uses: Mattraks/delete-workflow-runs@v2
with:
token: ${{ github.token }}
repository: ${{ github.repository }}
retain_days: 30
keep_minimum_runs: 6