diff options
| author | Stefan Becker <stefanb2@users.noreply.github.com> | 2023-03-27 16:31:02 +0300 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-03-27 14:31:02 +0100 |
| commit | 0db41e35efc3ebee7c334e11ae8d91607ef5931a (patch) | |
| tree | 94199d6ff6b1d427146f7556b0f55eb9a1cf60b2 | |
| parent | cf40e4b299ca4023f842eed1ecc5b254eb3eb688 (diff) | |
Ensure that deploy is always owned by user (#680)
Switch "docker cp" to tar streaming mode. As the receiving "tar" command
is executed outside Docker the resulting directories & files are owned
by the calling user.
| -rwxr-xr-x | build-docker.sh | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/build-docker.sh b/build-docker.sh index b3995d5..413c12a 100755 --- a/build-docker.sh +++ b/build-docker.sh @@ -126,8 +126,9 @@ else wait "$!" fi +# Ensure that deploy/ is always owned by calling user echo "copying results from deploy/" -${DOCKER} cp "${CONTAINER_NAME}":/pi-gen/deploy . +${DOCKER} cp "${CONTAINER_NAME}":/pi-gen/deploy - | tar -xf - ls -lah deploy # cleanup |
