mirror of
https://github.com/zitadel/zitadel.git
synced 2025-10-23 10:29:20 +00:00
chore: speed up build (#4017)
* better cache dependencies * ignore local statik.go * remove previously generated statik.go file * remove redundant .dockerignore
This commit is contained in:
@@ -3,10 +3,16 @@ ARG NODE_VERSION=16
|
||||
#######################
|
||||
## With this step we prepare all node_modules, this helps caching the build
|
||||
## Speed up this step by mounting your local node_modules directory
|
||||
## We also copy and generate the source code
|
||||
#######################
|
||||
FROM node:${NODE_VERSION} as npm-base
|
||||
WORKDIR /console
|
||||
|
||||
# Dependencies
|
||||
COPY console/package.json console/package-lock.json ./
|
||||
RUN npm ci
|
||||
|
||||
# Sources
|
||||
COPY console .
|
||||
COPY --from=zitadel-base:local /proto /proto
|
||||
COPY --from=zitadel-base:local /usr/local/bin /usr/local/bin/.
|
||||
@@ -24,12 +30,8 @@ COPY --from=npm-base /console/src/app/proto/generated /console/src/app/proto/gen
|
||||
#######################
|
||||
FROM npm-base as angular-build
|
||||
|
||||
COPY console/package.json console/package-lock.json ./
|
||||
RUN npm ci
|
||||
|
||||
RUN npm run lint
|
||||
RUN npm run prodbuild
|
||||
RUN ls -la /console/dist/console
|
||||
|
||||
#######################
|
||||
## Only Copy Assets
|
||||
|
Reference in New Issue
Block a user