utils/docker-run: also mount current working directory
Currently, using utils/docker-run expects that the current working directory is the working copy. This means that it is not possible to use docker-run with an out-of-tree build (one using O=). Add the current working directory to the list of mountpoints, and use that as working directory in the container. Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr> Cc: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
This commit is contained in:
parent
e71fb8f71c
commit
db777eef13
@ -17,10 +17,13 @@ declare -a docker_opts=(
|
||||
-i
|
||||
--rm
|
||||
--user "$(id -u):$(id -g)"
|
||||
--workdir "${MAIN_DIR}"
|
||||
--workdir "$(pwd)"
|
||||
)
|
||||
|
||||
declare -a mountpoints=( "${MAIN_DIR}" )
|
||||
declare -a mountpoints=(
|
||||
"${MAIN_DIR}"
|
||||
"$(pwd)"
|
||||
)
|
||||
|
||||
# Empty GIT_DIR means that we are not in a workdir, *and* git is too old
|
||||
# to know about worktrees, so we're not in a worktree either. So it means
|
||||
|
Loading…
Reference in New Issue
Block a user