-
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #14 from voxpupuli/update_build
feat: do multi stage build, remove package-lock.json, add usage for gitlab to README
- Loading branch information
Showing
3 changed files
with
37 additions
and
16,303 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,13 @@ | ||
FROM node:22.9.0-alpine3.20 | ||
FROM node:22.8.0-alpine3.20 AS build | ||
|
||
WORKDIR /npm | ||
COPY package.json /npm | ||
|
||
RUN npm install | ||
|
||
############################################################################### | ||
|
||
FROM node:22.8.0-alpine3.20 AS final | ||
|
||
LABEL org.label-schema.maintainer="Voxpupuli Team <[email protected]>" \ | ||
org.label-schema.vendor="Voxpupuli" \ | ||
|
@@ -9,21 +18,11 @@ LABEL org.label-schema.maintainer="Voxpupuli Team <[email protected]>" \ | |
org.label-schema.schema-version="1.0" \ | ||
org.label-schema.dockerfile="/Dockerfile" | ||
|
||
RUN apk update \ | ||
&& apk upgrade \ | ||
&& apk add --no-cache --update git git-lfs openssh-client | ||
|
||
# TODO: https://github.com/voxpupuli/container-semantic-release/issues/3 | ||
# RUN addgroup -g 1001 release && adduser -G release -u 1001 -D semantic \ | ||
# && mkdir -p /npm /data \ | ||
# && chown -R semantic:release /npm /data | ||
# USER semantic | ||
RUN apk update && apk upgrade \ | ||
&& apk add --no-cache --update git git-lfs openssh-client bash | ||
|
||
WORKDIR /npm | ||
COPY Dockerfile / | ||
COPY package.json package-lock.json /npm/ | ||
|
||
RUN npm ci | ||
COPY --from=build /npm /npm | ||
|
||
WORKDIR /data | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.