Skip to content

cleanup-stacks

cleanup-stacks #1155

name: cleanup-stacks
on:
schedule:
- cron: "0 */3 * * *"
workflow_dispatch:
jobs:
cleanup:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: jbrunton/cleanup-pulumi-stacks@v2
with:
working-directory: pulumi
verbose: true
preview: false
config: |
policies:
dev:
match:
name: '!(staging|production)'
ttl:
hours: 6
staging:
match:
name: staging
ttl:
hours: 24
production:
match:
name: production
ttl:
hours: 24
env:
PULUMI_ACCESS_TOKEN: ${{ secrets.PULUMI_ACCESS_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
AWS_REGION: us-east-1