refs #17782
Arvados-DCO-1.1-Signed-off-by: Ward Vandewege <ward@curii.com>
{
"variables": {
- "key_file": "{{env `packerbuildkey`}}"
+ "key_file": "{{env `packerbuildkey`}}",
+ "git_hash": "{{env `git_hash`}}"
},
"builders": [
{
},
{
"type": "shell",
+ "environment_vars": [
+ "GIT_HASH={{ user `git_hash` }}"
+ ],
"script": "./jenkins-image-workbench2.sh"
}
]
# Get the wb2 repository
cd /usr/src
sudo git clone https://git.arvados.org/arvados-workbench2.git
+cd arvados-workbench2
+
+if [[ "$GIT_HASH" != "" ]]; then
+ echo "GIT_HASH is set to $GIT_HASH, checking out that revision..."
+ sudo git checkout $GIT_HASH
+fi
# Build the workbench2-build docker image
-cd arvados-workbench2
sudo make workbench2-build-image
cd ..