feat(deploy): publish image to GHCR and document Synology DSM setup
Add a release workflow that publishes a linux/amd64 image to ghcr.io/richardnixondev/reddit-media-collector on every v* tag, plus a ready-to-paste docker-compose for Synology Container Manager. Persist scheduler state across container restarts by reading the DB and config paths from RMC_SCHEDULER_DB / RMC_SCHEDULER_CONFIG (previously written to /app, which is not a volume). Drive-by fixes uncovered while smoke-testing the image: - Dockerfile now copies README.md (required by pyproject) and drops the single-file VOLUME entry that breaks bind mounts; adds an OCI source label and a socket-based HEALTHCHECK so Container Manager reflects real liveness. - src/web/app.py uses the new Starlette TemplateResponse signature so the index page does not 500 under fresh dependency pins.
This commit is contained in:
parent
b7265f0582
commit
d02e071ddf
6 changed files with 135 additions and 9 deletions
43
.github/workflows/release.yml
vendored
Normal file
43
.github/workflows/release.yml
vendored
Normal file
|
|
@ -0,0 +1,43 @@
|
|||
name: release
|
||||
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- "v*"
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
publish:
|
||||
runs-on: ubuntu-latest
|
||||
permissions:
|
||||
contents: read
|
||||
packages: write
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
|
||||
- uses: docker/setup-buildx-action@v3
|
||||
|
||||
- uses: docker/login-action@v3
|
||||
with:
|
||||
registry: ghcr.io
|
||||
username: ${{ github.actor }}
|
||||
password: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
- id: meta
|
||||
uses: docker/metadata-action@v5
|
||||
with:
|
||||
images: ghcr.io/${{ github.repository_owner }}/reddit-media-collector
|
||||
tags: |
|
||||
type=semver,pattern={{version}}
|
||||
type=semver,pattern={{major}}.{{minor}}
|
||||
type=raw,value=latest,enable=${{ github.ref_type == 'tag' }}
|
||||
|
||||
- uses: docker/build-push-action@v6
|
||||
with:
|
||||
context: .
|
||||
platforms: linux/amd64
|
||||
push: true
|
||||
tags: ${{ steps.meta.outputs.tags }}
|
||||
labels: ${{ steps.meta.outputs.labels }}
|
||||
cache-from: type=gha
|
||||
cache-to: type=gha,mode=max
|
||||
Loading…
Add table
Add a link
Reference in a new issue