novelai-bot/.gitea/workflows/cleanup_registry.yaml
wirehack7 992615a42f
Some checks failed
Safety Check / safety-check (push) Successful in -2s
Code Quality Check / quality-check (push) Failing after 13s
added cleanup
2025-05-01 12:44:13 +02:00

24 lines
735 B
YAML

name: Cleanup old Docker images
on:
schedule:
- cron: '0 6 * * *' # Täglich um 6 Uhr
workflow_dispatch:
jobs:
cleanup:
runs-on: ubuntu-latest
steps:
- name: Install crane (OCI Registry tool)
run: |
curl -LO https://github.com/google/go-containerregistry/releases/latest/download/go-containerregistry_Linux_x86_64.tar.gz
tar -xzf go-containerregistry_Linux_x86_64.tar.gz
chmod +x crane
sudo mv crane /usr/local/bin/
- name: List Docker tags
run: |
crane ls git.0day.agency/${{ secrets.REGISTRY_USERNAME }}/novelai-discord-bot \
--username ${{ secrets.REGISTRY_USERNAME }} \
--password ${{ secrets.REGISTRY_TOKEN }}