Skip to content

An open-source, self-hostable PaaS alternative to Vercel, Heroku & Netlify that lets you easily deploy static sites, databases, full-stack applications and 360+ one-click services on your own servers.

ci: delete unused manifests every hour

peaklabs-dev26f8c990a540
diff --git a/.github/workflows/clean-manifests.yaml b/.github/workflows/clean-manifests.yaml
new file mode 100644
index 0000000000..bd1899214f
--- /dev/null
+++ b/.github/workflows/clean-manifests.yaml
@@ -0,0 +1,51 @@
+name: Clean manifests
+
+on:
+ schedule:
+ - cron: "20 * * * *"
+ workflow_dispatch:
+
+permissions: {}
+
+cache-mode: none
+
+concurrency:
+ group: clean-manifests
+ cancel-in-progress: false
+
+defaults:
+ run:
+ shell: bash
+
+jobs:
+ clean:
+ name: Clean
+ if: ${{ github.repository == 'coollabsio/coolify' }}
+ permissions:
+ contents: read
+ environment:
+ name: cleanup
+ deployment: false
+ runs-on: ubuntu-26.04 # https://github.com/actions/runner-images
+ timeout-minutes: 60
+ steps:
+ - name: Check out the repository
+ uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
+ with:
+ persist-credentials: false
+
+ - name: Delete the unused manifests
+ env:
+ GH_TOKEN: ${{ secrets.GHCR_CLEANUP_TOKEN }}
+ DOCKERHUB_USERNAME: ${{ secrets.DOCKERHUB_CLEANUP_USERNAME }}
+ DOCKERHUB_TOKEN: ${{ secrets.DOCKERHUB_CLEANUP_TOKEN }}
+ run: scripts/clean-manifests.sh --delete 200
+
+ - name: Upload the list of deleted manifests
+ if: ${{ always() }}
+ uses: actions/upload-artifact@cf430e030ddbb5b0abf93d22962f4752f3646cd9 # v7.0.2
+ with:
+ name: deleted-manifests
+ path: scripts/deleted-manifests.tsv
+ if-no-files-found: ignore
+ retention-days: 90