Use BUFSIZE when putting file as well as fetching file.
parent
270be6a6f5
commit
548a7288a9
|
@ -121,7 +121,7 @@ class Connection(object):
|
||||||
try:
|
try:
|
||||||
with open(in_path, 'rb') as in_file:
|
with open(in_path, 'rb') as in_file:
|
||||||
try:
|
try:
|
||||||
p = self._buffered_exec_command('dd of=%s' % out_path, None, stdin=in_file)
|
p = self._buffered_exec_command('dd of=%s bs=%s' % (out_path, BUFSIZE), None, stdin=in_file)
|
||||||
except OSError:
|
except OSError:
|
||||||
raise errors.AnsibleError("chroot connection requires dd command in the chroot")
|
raise errors.AnsibleError("chroot connection requires dd command in the chroot")
|
||||||
try:
|
try:
|
||||||
|
|
|
@ -143,7 +143,7 @@ class Connection(object):
|
||||||
try:
|
try:
|
||||||
with open(in_path, 'rb') as in_file:
|
with open(in_path, 'rb') as in_file:
|
||||||
try:
|
try:
|
||||||
p = self._buffered_exec_command('dd of=%s' % out_path, None, stdin=in_file)
|
p = self._buffered_exec_command('dd of=%s bs=%s' % (out_path, BUFSIZE), None, stdin=in_file)
|
||||||
except OSError:
|
except OSError:
|
||||||
raise errors.AnsibleError("jail connection requires dd command in the jail")
|
raise errors.AnsibleError("jail connection requires dd command in the jail")
|
||||||
try:
|
try:
|
||||||
|
|
|
@ -156,7 +156,7 @@ class Connection(object):
|
||||||
try:
|
try:
|
||||||
with open(in_path, 'rb') as in_file:
|
with open(in_path, 'rb') as in_file:
|
||||||
try:
|
try:
|
||||||
p = self._buffered_exec_command('dd of=%s' % out_path, None, stdin=in_file)
|
p = self._buffered_exec_command('dd of=%s bs=%s' % (out_path, BUFSIZE), None, stdin=in_file)
|
||||||
except OSError:
|
except OSError:
|
||||||
raise errors.AnsibleError("jail connection requires dd command in the jail")
|
raise errors.AnsibleError("jail connection requires dd command in the jail")
|
||||||
try:
|
try:
|
||||||
|
|
Loading…
Reference in New Issue