update docker deployment and changing seed kandang name

This commit is contained in:
Alberto-Audrix committed 2026-08-31 11:10:32 +07:00
1 parent 76f4d0106a
commit 74dd3faf60
40 files changed
+1253 -122

No files matched your search

+25
View File
@@ -0,0 +1,25 @@
# Frontend — multi-stage build (Vite + Nginx)
FROM node:20-alpine AS builder
WORKDIR /app
COPY package*.json ./
RUN npm ci
COPY . .
ENV VITE_API_BASE=/api/v1
RUN npm run build
FROM nginx:alpine
COPY --from=builder /app/dist /usr/share/nginx/html
COPY docker/nginx.conf /etc/nginx/conf.d/default.conf
EXPOSE 80
HEALTHCHECK --interval=30s --timeout=3s --start-period=10s --retries=3 \
CMD wget --quiet --tries=1 --spider http://localhost:80/health || exit 1
CMD ["nginx", "-g", "daemon off;"]