mirror of
https://github.com/dokku/dokku.git
synced 2025-12-28 16:06:40 +01:00
Merge pull request #3282 from dokku/3272-better-copy-from-image
feat: use create instead of run for faster and more reliable file copy from docker images
This commit is contained in:
@@ -325,7 +325,7 @@ copy_from_image() {
|
||||
[[ -z "$WORKDIR" ]] && local WORKDIR=/app
|
||||
local SRC_FILE="$WORKDIR/$SRC_FILE"
|
||||
fi
|
||||
local CID=$(docker run "$DOKKU_GLOBAL_RUN_ARGS" -d "$IMAGE" bash)
|
||||
local CID=$(docker create "$DOKKU_GLOBAL_RUN_ARGS" "$IMAGE")
|
||||
docker cp "$CID:$SRC_FILE" "$DST_DIR"
|
||||
docker rm -f "$CID" &> /dev/null
|
||||
else
|
||||
|
||||
1
tests.mk
1
tests.mk
@@ -5,7 +5,6 @@ ifneq ($(shell shellcheck --version > /dev/null 2>&1 ; echo $$?),0)
|
||||
ifeq ($(SYSTEM),Darwin)
|
||||
brew install shellcheck
|
||||
else
|
||||
sudo apt-key adv --keyserver ha.pool.sks-keyservers.net --recv-keys 5072E1F5
|
||||
sudo add-apt-repository 'deb http://archive.ubuntu.com/ubuntu trusty-backports main restricted universe multiverse'
|
||||
sudo rm -rf /var/lib/apt/lists/* && sudo apt-get clean
|
||||
sudo apt-get update -qq && sudo apt-get install -qq -y shellcheck
|
||||
|
||||
Reference in New Issue
Block a user