Skip to content

ale8k is updating trivy DB mirror #249

ale8k is updating trivy DB mirror

ale8k is updating trivy DB mirror #249

name: Mirror Trivy DB
run-name: ${{ github.actor }} is updating trivy DB mirror
on:
workflow_dispatch:
schedule:
- cron: '0 */6 * * *'
jobs:
mirror:
runs-on: ubuntu-latest
steps:
- name: "Install ORAS"
uses: oras-project/setup-oras@v1
- name: "Pull trivy-db"
run: oras pull ghcr.io/aquasecurity/trivy-db:2
- name: "Log in to GHCR with ORAS"
run: |
echo "${{ secrets.GITHUB_TOKEN }}" | oras login ghcr.io -u ${{ github.actor }} --password-stdin
- name: "Mirror trivy db"
run: oras cp ghcr.io/aquasecurity/trivy-db:2 ghcr.io/${{ github.repository }}/trivy-db:2