bot-api/Dockerfile.dev

20 lines
451 B
Docker
Raw Normal View History

2024-04-20 10:39:35 +00:00
FROM oven/bun:1 as base
WORKDIR /usr/src/app
FROM base AS install
RUN mkdir -p /temp/dev
COPY package.json bun.lockb /temp/dev/
RUN cd /temp/dev && bun install --frozen-lockfile
FROM base AS release
COPY --from=install /temp/dev/node_modules node_modules
COPY --from=install /temp/dev/package.json .
COPY ./src ./src
COPY ./tests ./tests
USER bun
ENV NODE_ENV dev
EXPOSE 8080/tcp
ENTRYPOINT [ "/bin/bash", "-c" ]
CMD ["bun --hot run src/index.ts"]