Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 23 additions & 1 deletion .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ on:

env:
IMAGE: ghcr.io/ivenos/compwire
DOCKERHUB_IMAGE: ivenos/compwire

jobs:
test:
Expand Down Expand Up @@ -63,11 +64,19 @@ jobs:
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Log in to Docker Hub
uses: docker/login-action@v4
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}

- name: Docker meta
id: meta
uses: docker/metadata-action@v6
with:
images: ${{ env.IMAGE }}
images: |
${{ env.IMAGE }}
docker.io/${{ env.DOCKERHUB_IMAGE }}
tags: |
type=raw,value=dev,enable=${{ github.ref == 'refs/heads/main' }}
type=semver,pattern={{version}}
Expand All @@ -84,3 +93,16 @@ jobs:
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}

- name: Prepare Docker Hub README
run: |
printf '**Note:** This description is automatically generated from the [GitHub repository README](https://github.com/ivenos/compwire).\n\n---\n\n' \
| cat - README.md > /tmp/dockerhub-readme.md

- name: Update Docker Hub description
uses: peter-evans/dockerhub-description@v5
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
repository: ${{ env.DOCKERHUB_IMAGE }}
readme-filepath: /tmp/dockerhub-readme.md