17 lines
442 B
Docker
17 lines
442 B
Docker
FROM node:22-alpine AS build
|
|
WORKDIR /app
|
|
COPY package*.json .npmrc ./
|
|
RUN npm ci
|
|
COPY . .
|
|
ARG VITE_SUPABASE_URL
|
|
ARG VITE_SUPABASE_ANON_KEY
|
|
ARG VITE_API_URL
|
|
RUN ./node_modules/.bin/vite build
|
|
|
|
FROM nginx:alpine
|
|
COPY --from=build /app/dist /usr/share/nginx/html
|
|
COPY nginx.conf /etc/nginx/conf.d/default.conf
|
|
EXPOSE 80
|
|
HEALTHCHECK --interval=30s --timeout=3s CMD wget -q --spider http://localhost/ || exit 1
|
|
CMD ["nginx", "-g", "daemon off;"]
|