Commit 73811f3c authored by Tobinsk's avatar Tobinsk
Browse files

Resolve "Build test image"

parent cdabb4fc
......@@ -25,6 +25,17 @@ build-docker:
- docker build --pull -t $CI_REGISTRY_IMAGE:$CI_COMMIT_SHA .
- docker push $CI_REGISTRY_IMAGE:$CI_COMMIT_SHA
# build and push test image
build-test-docker:
<<: *docker-login
stage: build
script:
- docker pull $CI_REGISTRY_IMAGE:latest || true
- docker build --build-arg VUE_APP_API_URL=https://api.test.metagrid.ch --pull -t $CI_REGISTRY_IMAGE:$CI_COMMIT_SHA .
- docker push $CI_REGISTRY_IMAGE:latest-test
only:
- master
push-latest:
<<: *docker-login
stage: push
......
# build stage
FROM node:lts-alpine as build-stage
FROM node:14-alpine as build-stage
RUN apk add --update --no-cache python3 make g++
WORKDIR /app
COPY package*.json ./
COPY yarn.lock ./
RUN yarn
COPY . .
# provide a varibae to change the api url
ARG VUE_APP_API_URL="https://api.metagrid.ch"
ENV VUE_APP_API_URL $VUE_APP_API_URL
RUN yarn run build
# production stage
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment