diff --git a/docker/red-ui/Dockerfile b/docker/red-ui/Dockerfile index 7ad8796ae..ec459a08b 100644 --- a/docker/red-ui/Dockerfile +++ b/docker/red-ui/Dockerfile @@ -1,19 +1,6 @@ -FROM node:18.12-buster as prep - -RUN apt-get update && apt-get install -y jq -COPY package.json /tmp -COPY version.json version.json -RUN cat version.json - -RUN jq '{ dependencies, devDependencies, peerDependencies, scripts: (.scripts | { postinstall }) }' < /tmp/package.json > /tmp/deps.json -# keep postinstall script - -### STAGE 1: Build ### - -# We label our stage as ‘builder’ FROM node:18.12-buster as builder -COPY --from=prep /tmp/deps.json ./package.json +COPY package.json package.json COPY yarn.lock ./ ## Storing node modules on a separate layer will prevent unnecessary npm installs at each build @@ -26,8 +13,6 @@ WORKDIR /ng-app COPY apps apps COPY libs libs COPY tools tools -COPY package.json package.json -COPY version.json version.json COPY yarn.lock yarn.lock COPY nx.json nx.json COPY .eslintrc.json .eslintrc.json @@ -46,8 +31,7 @@ CMD ["/bin/cp", "-r", "/ng-app/dist/paligo-styles", "/tmp/styles-export"] ### STAGE 2: Setup ### -FROM nginx:1.21.4-alpine -RUN apk add --update nano && rm -rf /var/cache/apk/* +FROM nginx:1.25.1-alpine ## Copy our default nginx config COPY docker/common/nginx/nginx.conf /etc/nginx/conf.d/default.conf diff --git a/version.json b/version.json new file mode 100644 index 000000000..ddc46b645 --- /dev/null +++ b/version.json @@ -0,0 +1,3 @@ +{ + "FROTEND_APP_VERSION": "development" +}