Update with modules

This commit is contained in:
TheMaddax 2024-11-23 21:19:49 -06:00
parent 932a73385f
commit b8cd5c7e3b

View file

@ -15,6 +15,7 @@ RUN npm install -g npm@latest
COPY package*.json ./ COPY package*.json ./
RUN npm ci RUN npm ci
RUN npm install -g typescript RUN npm install -g typescript
RUN npm install --save-dev @types/vite @vitejs/plugin-react
# Copy source code and build # Copy source code and build
COPY . . COPY . .
@ -25,10 +26,8 @@ FROM nginx:alpine
COPY --from=build /app/dist /usr/share/nginx/html COPY --from=build /app/dist /usr/share/nginx/html
COPY nginx.conf /etc/nginx/conf.d/default.conf COPY nginx.conf /etc/nginx/conf.d/default.conf
# Health check for container monitoring
HEALTHCHECK --interval=30s --timeout=10s --start-period=5s --retries=3 \ HEALTHCHECK --interval=30s --timeout=10s --start-period=5s --retries=3 \
CMD curl -f http://localhost/ || exit 1 CMD curl -f http://localhost/ || exit 1
# Expose port and start Nginx
EXPOSE 80 EXPOSE 80
CMD ["nginx", "-g", "daemon off;"] CMD ["nginx", "-g", "daemon off;"]