Skip to content

Commit

Permalink
Update image build
Browse files Browse the repository at this point in the history
- Use `npm ci` to avoid unpredictable updates
- Set the cache ownership to the container's user

Signed-off-by: Dale Haiducek <[email protected]>
  • Loading branch information
dhaiducek authored and openshift-merge-robot committed May 2, 2023
1 parent 3d5e910 commit fc896bf
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ WORKDIR /opt/magic-mirror

COPY package.json package-lock.json ./

RUN npm install
RUN npm ci

COPY . .

Expand All @@ -27,8 +27,10 @@ WORKDIR /opt/magic-mirror

COPY package.json package-lock.json ./

RUN npm install
RUN npm ci

COPY --from=build /opt/magic-mirror/build ./build

RUN chown -R 1000:1000 "/tmp"

USER 1000

0 comments on commit fc896bf

Please sign in to comment.