Implement Node.js backend rewrite with SQLite authentication, admin dashboard and One-Click docker update
This commit is contained in:
22
Dockerfile
22
Dockerfile
@@ -12,23 +12,23 @@ COPY . .
|
||||
|
||||
RUN bundle exec jekyll build
|
||||
|
||||
# === Serve-Phase: nginx + ImageMagick fuer Thumbnails ===
|
||||
FROM nginx:alpine
|
||||
# === Serve-Phase: node.js backend + ImageMagick ===
|
||||
FROM node:20-alpine
|
||||
|
||||
# Nginx als Root laufen lassen, um Berechtigungsprobleme mit Nextcloud-Dateien zu vermeiden
|
||||
RUN sed -i 's/user nginx;/user root;/g' /etc/nginx/nginx.conf
|
||||
RUN apk add --no-cache imagemagick docker-cli
|
||||
|
||||
RUN apk add --no-cache imagemagick
|
||||
WORKDIR /app
|
||||
COPY package*.json ./
|
||||
RUN npm install --omit=dev
|
||||
|
||||
COPY nginx.conf /etc/nginx/conf.d/default.conf
|
||||
COPY --from=builder /site/_site /usr/share/nginx/html
|
||||
COPY backend ./backend
|
||||
COPY --from=builder /site/_site ./public
|
||||
COPY entrypoint.sh /entrypoint.sh
|
||||
RUN chmod +x /entrypoint.sh
|
||||
|
||||
# Leere Bildverzeichnisse anlegen (werden durch Volumes ueberschrieben)
|
||||
RUN mkdir -p /usr/share/nginx/html/images/fulls \
|
||||
/usr/share/nginx/html/images/thumbs
|
||||
# Verzeichnisse anlegen
|
||||
RUN mkdir -p /app/public/images/fulls /app/public/images/thumbs /app/data
|
||||
|
||||
EXPOSE 80
|
||||
EXPOSE 8080
|
||||
|
||||
ENTRYPOINT ["/entrypoint.sh"]
|
||||
|
||||
Reference in New Issue
Block a user