From 383470b1a41ada11b8da025aa4caec83a8a1a4ea Mon Sep 17 00:00:00 2001 From: Ricky Stewart Date: Wed, 21 Feb 2024 12:37:34 -0600 Subject: [PATCH] Don't assume the location of this repository in `docker.sh` Allow it to be anywhere on disk. --- docker.sh | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/docker.sh b/docker.sh index 5326f4e4fa..6b027ca5a0 100755 --- a/docker.sh +++ b/docker.sh @@ -23,9 +23,6 @@ set -euo pipefail image=us-east1-docker.pkg.dev/crl-ci-images/cockroach/example-orms-builder:20200729-1723 -gopath=$(go env GOPATH) -gopath0=${gopath%%:*} - # Absolute path to this repository. repo_root=$(cd "$(dirname "${0}")" && pwd) @@ -46,7 +43,7 @@ echo "${username}:x:${uid_gid}::/home/${username}:/bin/bash" > "${container_root exec docker run \ --volume="${container_root}/etc/passwd:/etc/passwd" \ --volume="${container_root}/home/${username}:/home/${username}" \ - --volume="${gopath0}/src:/home/${username}/go/src" \ + --volume="${repo_root}:/home/${username}/go/src/github.com/cockroachdb/examples-orms" \ --workdir="/home/${username}/go/src/github.com/cockroachdb/examples-orms" \ --env=PIP_USER=1 \ --env=GEM_HOME="/home/${username}/.gems" \