Cleanup Staging Bucket #15
This file contains hidden or 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: Cleanup Staging Bucket | |
| on: | |
| # Run once a week at 02:00 UTC on Sunday | |
| schedule: | |
| - cron: "0 2 * * 0" | |
| # Also allow manual triggering from the Actions tab | |
| workflow_dispatch: | |
| jobs: | |
| cleanup: | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: read | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| - name: Set up Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: "3.13" | |
| - name: Install uv | |
| uses: astral-sh/setup-uv@v6 | |
| - name: Install project and dependencies | |
| run: | | |
| uv sync --all-extras --dev | |
| uv pip install -e . --no-deps | |
| - name: Run Cleanup Script | |
| run: uv run .github/scripts/cleanup_staging_bucket.py | |
| env: | |
| R2_ACCOUNT_ID: ${{ secrets.R2_ACCOUNT_ID }} | |
| R2_ACCESS_KEY_ID: ${{ secrets.R2_ACCESS_KEY_ID }} | |
| R2_SECRET_ACCESS_KEY: ${{ secrets.R2_SECRET_ACCESS_KEY }} | |
| R2_STAGING_BUCKET: ${{ vars.R2_STAGING_BUCKET }} |