feat: enable buildtime API_ENDPOINT env var

This commit is contained in:
Timothy J. Baek 2023-10-21 16:14:12 -07:00 committed by AJ ONeal
parent f4f1283cd5
commit 86395a8c1f
No known key found for this signature in database
GPG key ID: 65118FF2A9DB590F
10 changed files with 692 additions and 64 deletions

View file

@ -1,15 +1,20 @@
# syntax=docker/dockerfile:1
FROM node:latest
WORKDIR /app
ARG OLLAMA_API_ENDPOINT=''
RUN echo $OLLAMA_API_ENDPOINT
ENV ENV prod
ENV PUBLIC_API_ENDPOINT $OLLAMA_API_ENDPOINT
RUN echo $PUBLIC_API_ENDPOINT
COPY package.json package-lock.json ./
RUN npm ci
COPY . .
RUN npm run build
CMD [ "node", "./build/index.js"]
CMD [ "npm", "run", "start"]