From 0ea91d68591381f841693cfd2081864848849ee8 Mon Sep 17 00:00:00 2001 From: "russell@unturf.com" Date: Sun, 1 Feb 2026 17:17:00 -0500 Subject: [PATCH] Fix commit-hash.txt placement: copy into env before creating tarball --- .gitlab-ci.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 030fd94..ec5af5b 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -31,14 +31,14 @@ build: - rm -rf /opt/remarkbox/env # Clone the virtualenv with virtualenv-clone into the desired location. - virtualenv-clone -vvv $PWD/env /opt/remarkbox/env + # Create commit-hash.txt to track this build's git commit hash. + - echo $CI_COMMIT_SHA >> commit-hash.txt + # Place it inside the virtualenv before creating the tarball. + - cp commit-hash.txt /opt/remarkbox/env/commit-hash.txt # Create a tarball of the virtualenv. - tar -zcf env.tar.gz -C /opt/remarkbox . # Create a SHA512 hash of env.tar.gz. - sha512sum env.tar.gz >> env.tar.gz.hash - # Create commit-hash.txt to track this build's git commit hash. - - echo $CI_COMMIT_SHA >> commit-hash.txt - # Also place it inside the virtualenv so the deployed app can read it. - - cp commit-hash.txt /opt/remarkbox/env/commit-hash.txt artifacts: paths: - env.tar.gz