Reduce low risk duplication (#79)
* clean up helpers * shared in it's own top level folder * workspaces setup * build fix * disable workspaces? * run ci * rename job-flow to gradcracker * optional dependencies * formatting? * more optional modules * allow post install runs * node bump * remove post install * add optionals * add more * formatting * comments, but im unsure * run typescript DIRECTLY * better build * camoufox simplification * lint * build process doesn't exist * build fix * lockfile * type check everything, build only for client * rename steps correctly * import from package! * fix formatting * don't fetch twice * fix concern
This commit is contained in:
@@ -7,8 +7,9 @@ FROM apify/actor-node-playwright-chrome:20-1.50.1 AS builder
|
||||
# to speed up the build using Docker layer cache.
|
||||
COPY --chown=myuser package*.json ./
|
||||
|
||||
# Install all dependencies. Don't audit to speed up the installation.
|
||||
RUN npm install --include=dev --audit=false
|
||||
# Install all dependencies with cache mount for faster rebuilds
|
||||
RUN --mount=type=cache,target=/root/.npm \
|
||||
npm install --include=dev --audit=false --progress=false
|
||||
|
||||
# Next, copy the source files using the user set
|
||||
# in the base image.
|
||||
@@ -33,14 +34,16 @@ ENV PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD=0
|
||||
# Install NPM packages, skip optional and development dependencies to
|
||||
# keep the image small. Avoid logging too much and print the dependency
|
||||
# tree for debugging
|
||||
RUN npm --quiet set progress=false \
|
||||
&& npm install --omit=dev \
|
||||
RUN --mount=type=cache,target=/root/.npm \
|
||||
npm --quiet set progress=false \
|
||||
&& npm install --omit=dev --progress=false \
|
||||
&& echo "Installed NPM packages:" \
|
||||
&& (npm list --omit=dev --all || true) \
|
||||
&& echo "Node.js version:" \
|
||||
&& node --version \
|
||||
&& echo "NPM version:" \
|
||||
&& npm --version
|
||||
&& npm --version \
|
||||
&& npm run get-binaries
|
||||
|
||||
# Next, copy the remaining files and directories with the source code.
|
||||
# Since we do this after NPM install, quick build will be really fast
|
||||
|
||||
Reference in New Issue
Block a user