Skip to content

artifacthub-metadata #3

artifacthub-metadata

artifacthub-metadata #3

name: artifacthub-metadata
on:
push:
branches:
- main
paths:
- "artifacthub-repo.yml"
workflow_dispatch: # allow manually triggering builds
concurrency:
# only run one build at a time
group: ${{ github.workflow }}-${{ github.ref || github.run_id }}
cancel-in-progress: true
jobs:
artifacthub-repo-metadata:
name: Update artifacthub repo metadata
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
id-token: write
steps:
# clones user's repo
- uses: actions/checkout@v4
- name: Log in to the Container registry
uses: docker/login-action@65b78e6e13532edd9afa3aa52ac7964289d1a9c1
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Setup ORAS
uses: oras-project/setup-oras@v1
- run: oras version
# TODO: remove hardcoded values here
- run: oras push ghcr.io/detiber/beardy-os:artifacthub.io --config /dev/null:application/vnd.cncf.artifacthub.config.v1+yaml artifacthub-repo.yml:application/vnd.cncf.artifacthub.repository-metadata.layer.v1.yaml