From 1f97a1da3c4053196c2fd7a87f480c32d4957845 Mon Sep 17 00:00:00 2001 From: Nuwan Goonasekera <2070605+nuwang@users.noreply.github.com> Date: Wed, 23 Feb 2022 19:01:13 +0530 Subject: [PATCH] Add version.json for extra api information on commit hash and build date of docker container --- .k8s_ci.Dockerfile | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.k8s_ci.Dockerfile b/.k8s_ci.Dockerfile index 06e5bbcaca8..8215825ded4 100644 --- a/.k8s_ci.Dockerfile +++ b/.k8s_ci.Dockerfile @@ -176,6 +176,10 @@ COPY --chown=$GALAXY_USER:$GALAXY_USER --from=server_build $ROOT_DIR . COPY --chown=$GALAXY_USER:$GALAXY_USER --from=client_build $SERVER_DIR/static ./server/static WORKDIR $SERVER_DIR + +# The data in version.json will be displayed in Galaxy's /api/version endpoint +RUN printf "{\n \"git_commit\": \"$(cat GITREVISION)\",\n \"build_date\": \"$BUILD_DATE\",\n \"image_tag\": \"$IMAGE_TAG\"\n}\n" > version.json + EXPOSE 8080 USER $GALAXY_USER