Skip to content

fix env vars

fix env vars #10

name: delete-old-versions-in-archive
on:
workflow_dispatch:
pull_request:
paths:
- .github/workflows/delete-old-versions-in-archive.yml
- .github/scripts/delete-old-cloudsmith-artifacts.sh
branches:
- master
push:
paths:
- .github/workflows/delete-old-versions-in-archive.yml
- .github/scripts/delete-old-cloudsmith-artifacts.sh
branches:
- master
- glebashink/gh-action-delete-old-versions-in-archive
schedule:
- cron: '0 6 * * *'
jobs:
delete-old-versions-in-archive:
runs-on: ubuntu-latest
steps:
- name: Pull Fedora Docker image
run: docker pull fedora:latest
- name: Checkout code
uses: actions/checkout@v4
- name: Run script in Fedora Docker container
run: |
docker run --rm \
-e SCREWDRIVER=1 \
-e SD_PULL_REQUEST=$([[ "${{ github.event_name }}" == "pull_request" ]] && echo 1 || echo "") \
-e CLOUDSMITH_API_CREDS=${{ secrets.CLOUDSMITH_API_CREDS }} \
-v ${{ github.workspace }}:/workspace -w /workspace \
fedora:latest bash .github/scripts/delete-old-cloudsmith-artifacts.sh