Skip to content

Commit

Permalink
Don't assume the location of this repository in docker.sh
Browse files Browse the repository at this point in the history
Allow it to be anywhere on disk.
  • Loading branch information
rickystewart committed Feb 21, 2024
1 parent 89b68fa commit 383470b
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions docker.sh
Original file line number Diff line number Diff line change
Expand Up @@ -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)

Expand All @@ -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" \
Expand Down

0 comments on commit 383470b

Please sign in to comment.