first commit

This commit is contained in:
2025-11-19 01:09:25 -03:00
parent e7a380f36e
commit be10a888fb
28 changed files with 2481 additions and 464 deletions

View File

@@ -1,3 +1,4 @@
# Build stage
FROM node:18-alpine AS builder
WORKDIR /app
@@ -5,26 +6,19 @@ WORKDIR /app
# Copiar package files
COPY package*.json ./
# Instalar todas las dependencias (necesitamos las dev para el build)
# Instalar dependencias
RUN npm install
# Copiar código
# Copiar código fuente
COPY . .
# Build argument para la URL de la API
ARG VITE_API_URL=http://checklist-rons-0e8a3a-63dbc4-72-61-106-199.traefik.me
ENV VITE_API_URL=$VITE_API_URL
# Mostrar la URL que se está usando (para debug)
RUN echo "Building with VITE_API_URL=${VITE_API_URL}"
# Construir la aplicación
# Build de producción
RUN npm run build
# Etapa de producción con Nginx
# Production stage
FROM nginx:alpine
# Copiar archivos construidos
# Copiar build al nginx
COPY --from=builder /app/dist /usr/share/nginx/html
# Copiar configuración de nginx
@@ -33,5 +27,5 @@ COPY nginx.conf /etc/nginx/conf.d/default.conf
# Exponer puerto 80
EXPOSE 80
# Comando para iniciar nginx
# Comando por defecto
CMD ["nginx", "-g", "daemon off;"]