diff --git a/Dockerfile b/Dockerfile index c65a3c5..eb2f3df 100644 --- a/Dockerfile +++ b/Dockerfile @@ -15,8 +15,8 @@ RUN bundle exec jekyll build # === Serve-Phase: node.js backend + ImageMagick === FROM node:20-alpine -# ImageMagick fuer Thumbnails, Build-Tools fuer sqlite3 native bindings -RUN apk add --no-cache imagemagick python3 make g++ build-base sqlite-dev +# ImageMagick fuer Thumbnails, Docker CLI fuer Admin-Sync, Build-Tools fuer sqlite3 native bindings +RUN apk add --no-cache imagemagick docker-cli python3 make g++ build-base sqlite-dev WORKDIR /app COPY package*.json ./ diff --git a/README.md b/README.md index 59c2591..b6d726b 100644 --- a/README.md +++ b/README.md @@ -28,6 +28,8 @@ services: - INITIAL_ADMIN_PASSWORD=Start123 - FULLS_DIR=/app/public/images/fulls - THUMBS_DIR=/app/public/images/thumbs + - SYNC_IMAGE=ghcr.io/kroonk/photography:latest + - SYNC_CONTAINER=photography-website volumes: - /path/to/nextcloud/data:/app/public/images/fulls:ro - thumbs:/app/public/images/thumbs @@ -44,6 +46,8 @@ Change the initial admin password after the first login. If you prefer not to st node -e "const bcrypt = require('bcryptjs'); console.log(bcrypt.hashSync('your-admin-password', 10));" ``` +The admin dashboard includes a sync button that pulls `SYNC_IMAGE` and restarts `SYNC_CONTAINER`. This requires the Docker socket mount shown above. + ## Credits & License - Originally based on a Jekyll template. - UI Design by [AJ / HTML5 UP](https://html5up.net). diff --git a/admin.html b/admin.html index 1f7835d..9ce97d4 100644 --- a/admin.html +++ b/admin.html @@ -74,6 +74,13 @@ +
Laedt das neueste Docker-Image und startet den Website-Container neu.
+ + +