feat: docker dev setup

This commit is contained in:
Kailasdevdas
2026-04-20 14:39:29 +05:30
parent e356aa8fd9
commit 671a3c4e3a
5 changed files with 186 additions and 0 deletions
+24
View File
@@ -0,0 +1,24 @@
ARG NODE_VERSION=22.11.0
FROM node:${NODE_VERSION}-alpine
WORKDIR /usr/src/app
# Use cache mounts for faster installs
RUN --mount=type=bind,source=backend/package.json,target=package.json \
--mount=type=bind,source=backend/package-lock.json,target=package-lock.json \
--mount=type=cache,target=/root/.npm \
npm ci
# Copy the backend source
COPY ./backend .
# Copy and setup entrypoint
COPY ./docker/entrypoint.sh /usr/local/bin/entrypoint.sh
RUN chmod +x /usr/local/bin/entrypoint.sh
EXPOSE 5000
ENTRYPOINT [ "entrypoint.sh" ]
# This '$@' will be replaced by the CMD
CMD ["npm", "run", "dev"]