Skip to content

Develop #444

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jun 12, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
coverage
dist
node_modules
2 changes: 2 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
coverage
dist
node_modules
.serverless
.webpack
13 changes: 3 additions & 10 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ COPY ./Makefile ${WORKDIR}/
COPY ./.prettierrc ${WORKDIR}/
COPY ./.prettierignore ${WORKDIR}/
COPY ./.eslintrc ${WORKDIR}/
COPY ./.eslintignore ${WORKDIR}/
COPY ./.babelrc ${WORKDIR}/

# markdownlint conf
Expand All @@ -65,19 +66,12 @@ RUN npm ci --verbose --ignore-scripts
RUN ls -alh

# CMD []
WORKDIR ${WORKDIR}
###############################################################################
FROM base AS builder
FROM development AS builder

ENV WORKDIR=/app
WORKDIR ${WORKDIR}

COPY ./src ${WORKDIR}/src
COPY ./package.json ${WORKDIR}/package.json
COPY ./package-lock.json ${WORKDIR}/package-lock.json
COPY ./Makefile ${WORKDIR}/

RUN rm -vfr node_modules && npm ci --verbose --omit=dev --ignore-scripts
RUN npm run build

CMD ["ls", "-alh"]
Expand Down Expand Up @@ -114,13 +108,12 @@ ENV WORKDIR=/app
WORKDIR ${WORKDIR}

COPY --from=builder /app/dist ${WORKDIR}/dist
COPY --from=builder /app/node_modules ${WORKDIR}/node_modules

COPY ./Makefile ${WORKDIR}/
COPY ./package.json ${WORKDIR}/package.json
COPY ./package-lock.json ${WORKDIR}/package-lock.json
COPY ./Makefile ${WORKDIR}/

RUN npm ci --verbose --omit=dev --omit=optional --ignore-scripts --no-cache
RUN ls -alh

USER node
Expand Down