forked from caiodonascimento/navia-frontend
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
25 lines (19 loc) · 754 Bytes
/
Dockerfile
File metadata and controls
25 lines (19 loc) · 754 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
# syntax=docker/dockerfile:1
# Build stage: installs dependencies and creates the production bundle.
FROM node:20-alpine AS builder
WORKDIR /app
# Identificador del agente conversacional en ElevenLabs.
ARG VITE_ELEVENLABS_API_KEY
ARG VITE_ELEVENLABS_AGENT_ID
# Install dependencies with reliable layer caching.
COPY package.json package-lock.json ./
RUN npm ci
# Copy the remainder of the project and run the Vite build.
COPY . .
RUN npm run build -- --base=/navia/
# Runtime stage: serve the upstream page enhanced with Navia via OpenResty (Nginx + Lua).
FROM openresty/openresty:1.25.3.1-alpine AS runner
COPY nginx.conf /etc/nginx/conf.d/default.conf
COPY --from=builder /app/dist /usr/share/navia
EXPOSE 8080
CMD ["nginx", "-g", "daemon off;"]