mirror of https://github.com/docker/docker-py.git
Fix file mode in image.save examples
Signed-off-by: Joffrey F <joffrey@docker.com>
This commit is contained in:
parent
cebdee4aef
commit
852d79b08d
|
@ -32,7 +32,7 @@ class ImageApiMixin(object):
|
|||
Example:
|
||||
|
||||
>>> image = cli.get_image("busybox:latest")
|
||||
>>> f = open('/tmp/busybox-latest.tar', 'w')
|
||||
>>> f = open('/tmp/busybox-latest.tar', 'wb')
|
||||
>>> for chunk in image:
|
||||
>>> f.write(chunk)
|
||||
>>> f.close()
|
||||
|
|
|
@ -84,7 +84,7 @@ class Image(Model):
|
|||
Example:
|
||||
|
||||
>>> image = cli.get_image("busybox:latest")
|
||||
>>> f = open('/tmp/busybox-latest.tar', 'w')
|
||||
>>> f = open('/tmp/busybox-latest.tar', 'wb')
|
||||
>>> for chunk in image:
|
||||
>>> f.write(chunk)
|
||||
>>> f.close()
|
||||
|
|
Loading…
Reference in New Issue