Files
picobook/Dockerfile
T

27 lines
609 B
Docker
Raw Normal View History

2023-10-29 19:28:07 +00:00
# Installs Node image
2026-06-10 21:47:30 -04:00
FROM node:20-alpine as base
2023-10-29 19:28:07 +00:00
# sets the working directory for any RUN, CMD, COPY command
WORKDIR /app
2026-06-10 21:47:30 -04:00
# # Install Python and pip
# RUN apk add --update python3 py3-pip
# RUN python3 -m ensurepip
# RUN pip3 install --no-cache --upgrade pip setuptools
2023-10-29 13:28:00 -07:00
2026-06-10 21:47:30 -04:00
# COPY ./data ./data
2024-03-31 14:08:48 -07:00
2023-10-29 19:28:07 +00:00
# Copies stuff to cache for install
COPY ./package.json ./package-lock.json tsconfig.json ./
RUN echo "npm install"
RUN npm install
# Copies everything in the src directory to WORKDIR/src
COPY ./src ./src
COPY ./scripts ./scripts
# Run the server
RUN echo "npm run prod-start"
CMD ["npm", "run", "prod-start"]