Merge branch 'dev' into 'main'

Updted docker files

See merge request illegitimate/illegitimate-bot!112
This commit is contained in:
2023-11-30 18:11:54 +00:00
3 changed files with 12 additions and 0 deletions

View File

@@ -8,6 +8,7 @@ docker-build:
before_script: before_script:
- docker login -u "$CI_REGISTRY_USER" -p "$CI_REGISTRY_PASSWORD" $CI_REGISTRY - docker login -u "$CI_REGISTRY_USER" -p "$CI_REGISTRY_PASSWORD" $CI_REGISTRY
script: script:
- docker build . -f Dockerfile.cache -t node-cache
- docker build --pull -t "$DOCKER_IMAGE_NAME" . - docker build --pull -t "$DOCKER_IMAGE_NAME" .
- docker push "$DOCKER_IMAGE_NAME" - docker push "$DOCKER_IMAGE_NAME"
- | - |

View File

@@ -1,5 +1,10 @@
FROM node-cache as cache
FROM node:20.9.0-alpine3.18 FROM node:20.9.0-alpine3.18
COPY --from=cache /node_modules /app/node_modules
COPY package.json /app
COPY yarn.lock /app
COPY . /app COPY . /app
WORKDIR /app WORKDIR /app

6
Dockerfile.cache Normal file
View File

@@ -0,0 +1,6 @@
FROM node:20.9.0-alpine3.18
COPY package.json ./
COPY yarn.lock ./
RUN yarn install