make main a version off dev

This commit is contained in:
2025-07-23 21:25:24 +02:00
parent 5247bd9816
commit 74e4799ea9
49 changed files with 6594 additions and 280 deletions

View File

@ -1,18 +1,25 @@
FROM nginx:alpine
FROM node:20-alpine AS build
# Kopiere statische Dateien ins Nginx-Verzeichnis
COPY src/ /usr/share/nginx/html/
WORKDIR /app
# Konfiguriere NGINX für Single-Page-Applications (optional)
RUN echo 'server { \
listen 80; \
root /usr/share/nginx/html; \
index index.html; \
location / { \
try_files $uri $uri/ /index.html; \
} \
}' > /etc/nginx/conf.d/default.conf
COPY package*.json ./
RUN npm ci
EXPOSE 80
COPY ../backup/backup .
CMD ["nginx", "-g", "daemon off;"]
RUN npm run build
FROM node:20-alpine AS production
WORKDIR /app
RUN npm install -g serve
COPY --from=build /app/dist /app
EXPOSE 3000
CMD ["serve", "-s", ".", "-l", "3000"]
HEALTHCHECK --interval=30s --timeout=3s --start-period=5s --retries=3 \
CMD wget -qO- http://localhost:3000/ || exit 1