mirror of
https://github.com/Hessenuk/DiscordTickets.git
synced 2024-11-17 09:23:07 +02:00
perf(docker): reorder commands to improve caching (maybe?)
This commit is contained in:
parent
ec8589393b
commit
64da241a76
@ -2,12 +2,12 @@
|
|||||||
|
|
||||||
FROM node:18-alpine AS builder
|
FROM node:18-alpine AS builder
|
||||||
WORKDIR /build
|
WORKDIR /build
|
||||||
COPY package.json pnpm-lock.yaml ./
|
|
||||||
COPY --link scripts scripts
|
|
||||||
# install python etc so node-gyp works for the optional dependencies
|
# install python etc so node-gyp works for the optional dependencies
|
||||||
RUN apk add --no-cache make gcc g++ python3
|
RUN apk add --no-cache make gcc g++ python3
|
||||||
# install pnpm to make dependency installation faster (because it has a lockfile)
|
# install pnpm to make dependency installation faster (because it has a lockfile)
|
||||||
RUN npm install -g pnpm
|
RUN npm install -g pnpm
|
||||||
|
COPY package.json pnpm-lock.yaml ./
|
||||||
|
COPY --link scripts scripts
|
||||||
# install dependencies, CI=true to skip pre/postinstall scripts
|
# install dependencies, CI=true to skip pre/postinstall scripts
|
||||||
RUN CI=true pnpm install --prod --frozen-lockfile
|
RUN CI=true pnpm install --prod --frozen-lockfile
|
||||||
COPY --link . .
|
COPY --link . .
|
||||||
|
Loading…
Reference in New Issue
Block a user