ci: add image docs workflows

This commit is contained in:
Markus Küffner
2023-12-07 17:19:13 +01:00
parent f42023c27e
commit d755cd06c9
7 changed files with 106 additions and 1 deletions

View File

@@ -0,0 +1,18 @@
name: 'Docs: Klipper'
on:
push:
branches:
- main
paths:
- .github/workflows/template-image-docs-workflow.yaml
- docker/klipper/README.md
jobs:
docs:
uses: ./.github/workflows/template-image-docs-workflow.yaml
with:
app: klipper
short-description: "Klipper is a 3d-Printer firmware."
secrets:
DOCKERHUB_USERNAME: ${{ secrets.DOCKERHUB_USERNAME }}
DOCKERHUB_TOKEN: ${{ secrets.DOCKERHUB_TOKEN }}

View File

@@ -0,0 +1,18 @@
name: 'Docs: KlipperScreen'
on:
push:
branches:
- main
paths:
- .github/workflows/template-image-docs-workflow.yaml
- docker/klipperscreen/README.md
jobs:
docs:
uses: ./.github/workflows/template-image-docs-workflow.yaml
with:
app: klipperscreen
short-description: "KlipperScreen is a touchscreen GUI that interfaces with Klipper via Moonraker."
secrets:
DOCKERHUB_USERNAME: ${{ secrets.DOCKERHUB_USERNAME }}
DOCKERHUB_TOKEN: ${{ secrets.DOCKERHUB_TOKEN }}

View File

@@ -0,0 +1,18 @@
name: 'Docs: Moonraker'
on:
push:
branches:
- main
paths:
- .github/workflows/template-image-docs-workflow.yaml
- docker/moonraker/README.md
jobs:
docs:
uses: ./.github/workflows/template-image-docs-workflow.yaml
with:
app: moonraker
short-description: "Web API used to interact with the 3D printing firmware Klipper."
secrets:
DOCKERHUB_USERNAME: ${{ secrets.DOCKERHUB_USERNAME }}
DOCKERHUB_TOKEN: ${{ secrets.DOCKERHUB_TOKEN }}

View File

@@ -0,0 +1,18 @@
name: 'Docs: Ustreamer'
on:
push:
branches:
- main
paths:
- .github/workflows/template-image-docs-workflow.yaml
- docker/ustreamer/README.md
jobs:
docs:
uses: ./.github/workflows/template-image-docs-workflow.yaml
with:
app: ustreamer
short-description: "µStreamer is a lightweight and very quick server to stream MJPEG video"
secrets:
DOCKERHUB_USERNAME: ${{ secrets.DOCKERHUB_USERNAME }}
DOCKERHUB_TOKEN: ${{ secrets.DOCKERHUB_TOKEN }}

View File

@@ -1,4 +1,4 @@
name: image-build-workflow
name: "Template: image-build-workflow"
on:
workflow_call:
inputs:

View File

@@ -0,0 +1,32 @@
name: "Template: image-docs-workflow"
on:
workflow_call:
inputs:
app:
required: true
type: string
description: 'app image to build'
short-description:
required: true
type: string
description: 'Docker Hub repository short description'
secrets:
DOCKERHUB_USERNAME:
required: true
DOCKERHUB_TOKEN:
required: true
jobs:
image-docs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: "Update Docker Hub Description"
uses: peter-evans/dockerhub-description@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
repository: ${{ secrets.DOCKERHUB_USERNAME }}/${{ inputs.app }}
short-description: ${{ inputs.short-description }}
readme-filepath: ./docker/${{ inputs.app }}/README.md
enable-url-completion: true

View File

@@ -14,6 +14,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
- docker: pin base images to python:3.11-(slim-)bookworm
- extra: simplify moonraker-timelapse setup
- ci: restructure image build workflows
- ci: add image docs workflow to update dockerhub descriptions automatically
### Removed
-->