diff --git a/Dockerfile b/Dockerfile index 7969784a6..227c842ff 100644 --- a/Dockerfile +++ b/Dockerfile @@ -22,7 +22,7 @@ ENV YARN_VERSION 1.22.19 RUN yarn policies set-version $YARN_VERSION # Use non-root user -USER appuser +USER default # Copy package.json and package-lock.json/yarn.lock files COPY package*.json *yarn* ./ @@ -33,7 +33,7 @@ ENV PATH /app/node_modules/.bin:$PATH # USER root # RUN bash /tools/apt-install.sh build-essential -USER appuser +USER default RUN yarn config set network-timeout 300000 RUN yarn && yarn cache clean --force @@ -49,7 +49,7 @@ ARG NODE_ENV=development ENV NODE_ENV $NODE_ENV # copy in our source code last, as it changes the most -COPY --chown=appuser:appuser . . +COPY --chown=default:default . . # Bake package.json start command into the image CMD ["react-scripts", "start"] @@ -62,7 +62,7 @@ COPY . /app RUN yarn build # ============================= -FROM registry.access.redhat.com/ubi9/nginx-122 as production +FROM registry.access.redhat.com/ubi9/nginx-122 AS production # ============================= USER root