Commit ee0352eb authored by Nicolas Wavrant's avatar Nicolas Wavrant

pbs: promises redirect ssh output to /dev/null

parent bb8b4569
...@@ -40,10 +40,12 @@ from slapos.recipe.librecipe import shlex ...@@ -40,10 +40,12 @@ from slapos.recipe.librecipe import shlex
def promise(args): def promise(args):
ssh = subprocess.Popen( # Redirect output to /dev/null
[args['ssh_client'], '%(user)s@%(host)s' % args, '-p', '%(port)s' % args], with open("/dev/null") as _dev_null:
stdin=subprocess.PIPE, stdout=None, stderr=None ssh = subprocess.Popen(
) [args['ssh_client'], '%(user)s@%(host)s' % args, '-p', '%(port)s' % args],
stdin=subprocess.PIPE, stdout=_dev_null, stderr=_dev_null
)
# Rdiff Backup protocol quit command # Rdiff Backup protocol quit command
quitcommand = 'q' + chr(255) + chr(0) * 7 quitcommand = 'q' + chr(255) + chr(0) * 7
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment