You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Description
According to official docker documentation, docker cp src_path dest_path should support the following behavior: When src_path specifies and directory and ends with /. (for windows, \.), and the dest_path specifies an existing directory, the content of src_path (files and sub-directories) should be copied into dest_path. However, docker on windows gives an error instead in this case.
Steps to reproduce the issue:
On host machine: docker run -it --name test_container microsoft/nanoserver
Within the launched container: Create the the following directory and file C:\test_dir\test.txt, and then exit the container
On host machine: mkdir docker_test
On host machine: docker cp test_container:C:\test_dir\. .\docker_test
Describe the results you received:
Error response from daemon: GetFileAttributesEx \\?\Volume{71a5bce9-587d-4726-84a6-83f9c99ea9c7}\test_dir\.: The filename, directory name, or volume label syntax is incorrect
Describe the results you expected: test.txt file should appear in .\docker_test on host machine
Additional information you deem important (e.g. issue happens only occasionally):
Output of docker version:
Client:
Version: 17.06.1-ce
API version: 1.30
Go version: go1.8.3
Git commit: 874a737
Built: Thu Aug 17 22:48:20 2017
OS/Arch: windows/amd64
Server:
Version: 17.06.1-ce
API version: 1.30 (minimum version 1.24)
Go version: go1.8.3
Git commit: 874a737
Built: Thu Aug 17 23:03:03 2017
OS/Arch: windows/amd64
Experimental: true
Additional information:
I have also tried with various other kinds of src_path endings, including \, \*. None of them can correctly produce the behavior of copying content of a container directory (not the directory itself) to an existing host directory.
This issue is filed after discussion with @jhowardmsft.
@darrenstahlmsft @johnstep
The text was updated successfully, but these errors were encountered:
Description
According to official docker documentation,
docker cp src_path dest_path
should support the following behavior: Whensrc_path
specifies and directory and ends with/.
(for windows,\.
), and thedest_path
specifies an existing directory, the content ofsrc_path
(files and sub-directories) should be copied intodest_path
. However, docker on windows gives an error instead in this case.Steps to reproduce the issue:
docker run -it --name test_container microsoft/nanoserver
C:\test_dir\test.txt
, and then exit the containermkdir docker_test
docker cp test_container:C:\test_dir\. .\docker_test
Describe the results you received:
Describe the results you expected:
test.txt
file should appear in.\docker_test
on host machineAdditional information you deem important (e.g. issue happens only occasionally):
Output of
docker version
:Output of
docker info
:Additional information:
I have also tried with various other kinds of
src_path
endings, including\
,\*
. None of them can correctly produce the behavior of copying content of a container directory (not the directory itself) to an existing host directory.This issue is filed after discussion with @jhowardmsft.
@darrenstahlmsft @johnstep
The text was updated successfully, but these errors were encountered: