Tidy Deploy Preview Environment #654
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Tidy Deploy Preview Environment | |
on: | |
schedule: | |
# Runs "daily at 7:45 PM ET" (see https://crontab.guru) | |
- cron: '45 0 * * *' | |
jobs: | |
clean-environments: | |
name: Clean Deployments | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: volta-cli/action@v3 | |
- run: yarn | |
- name: Tidy Previews | |
run: node ./.scripts/humanitec.mjs tidy-previews | |
env: | |
# using built-in token for restricted access to only this repo | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
HUMANITEC_ORG_ID: ${{ secrets.HUMANITEC_ORG_ID }} | |
HUMANITEC_TOKEN: ${{ secrets.HUMANITEC_TOKEN }} |