Fix failing Webpack build
- Includes eslint-related files in Dockerfile build step - Switches to using a cache mount in Dockerfile build step for yarn cache, rather than deleting yarn cache, which should speed up most builds
This commit is contained in:
parent
172a9bf0cd
commit
ed08b734ba
@ -3,10 +3,8 @@ FROM --platform=$BUILDPLATFORM docker.io/library/node:18 as build_deps
|
||||
|
||||
WORKDIR /app
|
||||
COPY yarn.lock package.json ./
|
||||
# Uses `yarn cache clean` to let Docker cache layer instead
|
||||
# of including yarn cache in the build image
|
||||
RUN yarn --production --frozen-lockfile --ignore-optional --network-timeout 1000000 && \
|
||||
yarn cache clean
|
||||
# Uses a cache mount for the Yarn cache so that it's not included in subsequent steps
|
||||
RUN --mount=type=cache,target=/root/.yarn YARN_CACHE_FOLDER=/root/.yarn yarn --production --frozen-lockfile --ignore-optional --network-timeout 1000000
|
||||
|
||||
COPY --link lit-localize.json \
|
||||
postcss.config.js \
|
||||
@ -14,6 +12,8 @@ COPY --link lit-localize.json \
|
||||
tsconfig.json \
|
||||
webpack.config.js \
|
||||
webpack.prod.js \
|
||||
.eslintrc.js \
|
||||
tsconfig.eslint.json \
|
||||
index.d.ts \
|
||||
./
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user