Skip to content
Snippets Groups Projects
Commit afba2655 authored by Andrew Kapuscinski's avatar Andrew Kapuscinski
Browse files

add build arg for WS_VERSION in order to build the static site with the version correctly set

parent 02f0965d
No related branches found
No related tags found
1 merge request!961add build arg for WS_VERSION in order to build the static site with the version correctly set
Pipeline #5426 passed
FROM ssa-containers.aoc.nrao.edu/ops/base:nodejs-14 as base-build
# Requies build-arg $env
# Requires build-arg $env
# Build arg that sets environment; sets to "dev" if no build arg is given
ARG env=dev
ENV ENV=${env}
# Requires build-arg WS_VERSION
# Build arg that sets Workspaces Version; defaults to "dev" if no build arg is given
ARG WS_VERSION=dev
ENV NG_APP_WS_VERSION=${WS_VERSION}
# Switch to vlapipe
USER vlapipe
......
......@@ -3,7 +3,7 @@
script:
- echo "Building branch or tag -- ${IMAGE_TAG}"
- NAME="${REGISTRY_URL}/${PROJECT_NAME}/${SERVICE_NAME}"
- docker build -t ${NAME}:${CI_COMMIT_SHORT_SHA} -f ${PATH_PREFIX}${SERVICE_NAME}/Dockerfile . --build-arg env=${DEPLOY_ENV} --build-arg TAGNAME=${CI_COMMIT_SHORT_SHA}
- docker build -t ${NAME}:${CI_COMMIT_SHORT_SHA} -f ${PATH_PREFIX}${SERVICE_NAME}/Dockerfile . --build-arg env=${DEPLOY_ENV} --build-arg TAGNAME=${CI_COMMIT_SHORT_SHA} --build-arg WS_VERSION=${IMAGE_TAG}
- docker tag ${NAME}:${CI_COMMIT_SHORT_SHA} ${NAME}:${IMAGE_TAG}
- echo "TAG=${IMAGE_TAG}" >> build.env
artifacts:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment