mirror of
https://github.com/goauthentik/authentik.git
synced 2026-06-18 11:29:26 +03:00
3d5a189fa7
* don't push when on internal repo Signed-off-by: Jens Langhammer <jens@goauthentik.io> * only run certain workflows on main repo Signed-off-by: Jens Langhammer <jens@goauthentik.io> * add mirror Signed-off-by: Jens Langhammer <jens@goauthentik.io> * how tf did a tab get in there Signed-off-by: Jens Langhammer <jens@goauthentik.io> * ooops Signed-off-by: Jens Langhammer <jens@goauthentik.io> --------- Signed-off-by: Jens Langhammer <jens@goauthentik.io>
29 lines
861 B
YAML
29 lines
861 B
YAML
name: ghcr-retention
|
|
|
|
on:
|
|
# schedule:
|
|
# - cron: "0 0 * * *" # every day at midnight
|
|
workflow_dispatch:
|
|
|
|
jobs:
|
|
clean-ghcr:
|
|
if: ${{ github.repository != 'goauthentik/authentik-internal' }}
|
|
name: Delete old unused container images
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- id: generate_token
|
|
uses: tibdex/github-app-token@v2
|
|
with:
|
|
app_id: ${{ secrets.GH_APP_ID }}
|
|
private_key: ${{ secrets.GH_APP_PRIVATE_KEY }}
|
|
- name: Delete 'dev' containers older than a week
|
|
uses: snok/container-retention-policy@v2
|
|
with:
|
|
image-names: dev-server,dev-ldap,dev-proxy
|
|
cut-off: One week ago UTC
|
|
account-type: org
|
|
org-name: goauthentik
|
|
untagged-only: false
|
|
token: ${{ steps.generate_token.outputs.token }}
|
|
skip-tags: gh-next,gh-main
|