feat: install docker cli in backend

* change the copy order to improve performance
This commit is contained in:
Lin, Hung-Shin authored and wancat committed 2023-10-29 17:41:38 +08:00
1 parent 579d53a273
commit 38f3dbcd65
2 files changed
+3 -6

No files matched your search

+2 -5
View File
@@ -1,5 +1,6 @@
FROM node:20-alpine AS build
COPY --from=docker:dind /usr/local/bin/docker /usr/local/bin/
WORKDIR /app
COPY ./package.json yarn.lock ./
COPY server/package.json ./server/package.json
@@ -15,23 +16,19 @@ EXPOSE 3000
# Production
FROM build as prod
COPY ./server ./server
COPY packages/file-graph ./packages/file-graph
COPY packages/utils ./packages/utils
COPY packages/models ./packages/models
COPY ./server ./server
COPY quests ./quests
ENV NODE_ENV=production
WORKDIR /app/server
CMD [ "yarn", "start" ]
# Development
FROM build as dev
RUN yarn install --frozen-lockfile
ENV NODE_ENV=development
CMD [ "yarn", "server" ]