include version and commit hash in status endpoint

This commit is contained in:
Oscar Krause
2022-12-21 10:40:05 +01:00
parent fdaedacfa5
commit af6b17319d
5 changed files with 11 additions and 2 deletions

View File

@@ -8,6 +8,8 @@ build:
rules:
- if: $CI_COMMIT_BRANCH
tags: [ docker ]
before_script:
- echo "COMMIT=`git rev-parse HEAD`" >> version.env
script:
- docker login -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD $CI_REGISTRY
- docker build . --tag ${CI_REGISTRY}/${CI_PROJECT_PATH}/${CI_BUILD_REF_NAME}:${CI_BUILD_REF}