Skip to content

.github/workflows/withdraw-repos.yaml #16

.github/workflows/withdraw-repos.yaml

.github/workflows/withdraw-repos.yaml #16

on:
workflow_dispatch:
inputs:
dry_run:
type: boolean
default: 'true'
description: If true, just log
permissions:
contents: read
jobs:
withdraw:
runs-on: ubuntu-latest
permissions:
id-token: write
contents: read
steps:
- uses: step-security/harden-runner@a4aa98b93cab29d9b1101a6143fb8bce00e2eac4 # v2.7.1
with:
egress-policy: audit
- uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4
- uses: chainguard-dev/actions/setup-chainctl@538d1927b846546b620784754c33e2a1db86e217 # main
with:
identity: 720909c9f5279097d847ad02a2f24ba8f59de36a/b6461e99e132298f
- run: |
for repo in $(grep -v '\#' withdrawn-repos.txt); do
if [[ "${{ github.event.inputs.dry_run }}" == "false" ]]; then
chainctl image repo rm $repo || true
else
echo "DRY RUN: chainctl image repo rm $repo || true"
fi
done