Fix copy chown
All checks were successful
Build and Push Docker Image / build-and-push (push) Successful in 6m34s
All checks were successful
Build and Push Docker Image / build-and-push (push) Successful in 6m34s
This commit is contained in:
@@ -11,7 +11,7 @@ RUN chown node:node ./
|
||||
USER node
|
||||
|
||||
# Copy package files first
|
||||
COPY package.json package-lock.json* .
|
||||
COPY --chown=node:node package.json package-lock.json* .
|
||||
|
||||
# Install app dependencies
|
||||
ENV NODE_ENV=production
|
||||
@@ -20,7 +20,7 @@ RUN npm ci --only=production --ignore-scripts && \
|
||||
npm cache clean --force
|
||||
|
||||
# Copy the builded files
|
||||
COPY ./dist/* .
|
||||
COPY --chown=node:node ./dist/* .
|
||||
|
||||
# Return to root user to remove build dependencies
|
||||
USER root
|
||||
|
||||
Reference in New Issue
Block a user