build(docker/backend): replace more COPY with mount [skip ci]

This commit is contained in:
Sarah Vaupel 2025-01-23 17:15:45 +01:00
parent e95ad62436
commit 6895313887

View File

@ -39,11 +39,8 @@ ENV STACK_ROOT="${PROJECT_DIR}/.stack"
WORKDIR ${PROJECT_DIR}
ENV HOME=${PROJECT_DIR}
COPY stack.yaml ${PROJECT_DIR}/stack.yaml
COPY stack.yaml.lock ${PROJECT_DIR}/stack.yaml.lock
COPY package.yaml ${PROJECT_DIR}/package.yaml
RUN stack install yesod-bin
RUN stack install hpack
RUN --mount=type=bind,source=.,target=. stack install yesod-bin
RUN --mount=type=bind,source=.,target=. stack install hpack
# pre-build dependencies
RUN --mount=type=bind,source=.,target=. \