File tree 1 file changed +4
-4
lines changed
1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -13,15 +13,15 @@ import (
13
13
// ContainerExport writes the contents of the container to the given
14
14
// writer. An error is returned if the container cannot be found.
15
15
func (daemon * Daemon ) ContainerExport (name string , out io.Writer ) error {
16
- if runtime .GOOS == "windows" {
17
- return fmt .Errorf ("the daemon on this platform does not support export of a container" )
18
- }
19
-
20
16
container , err := daemon .GetContainer (name )
21
17
if err != nil {
22
18
return err
23
19
}
24
20
21
+ if runtime .GOOS == "windows" && container .Platform == "windows" {
22
+ return fmt .Errorf ("the daemon on this platform does not support exporting Windows containers" )
23
+ }
24
+
25
25
data , err := daemon .containerExport (container )
26
26
if err != nil {
27
27
return fmt .Errorf ("Error exporting container %s: %v" , name , err )
You can’t perform that action at this time.
0 commit comments