def runbench(bench):
     jid = multyvac.shell_submit(
         "/bin/bash {}/run.sh {}".format(scripts_vol.mount_path, bench),
         _name='bench1',
         _core='f2',
         _layer=args.layer,
         _vol=[args.scripts_volume, args.results_volume])
     return multyvac.get(jid)
示例#2
0
 def runbench(bench):
     jid = multyvac.shell_submit(
         "/bin/bash {}/run.sh {}".format(scripts_vol.mount_path, bench),
         _name='bench1',
         _core='f2',
         _layer=args.layer,
         _vol=[args.scripts_volume, args.results_volume])
     return multyvac.get(jid)
示例#3
0
        "cmd": 'echo "success" > /tmp/out',
        "_result_source": "file:/tmp/out",
    },
    "stdin": {
        "cmd": 'cat',
        "_stdin": "success",
    },
}

longest = 0
for name in jobs.keys():
    if len(name) > longest:
        longest = len(name)

success = 0
failure = 0

for (name, kwargs) in jobs.items():
    jid = multyvac.shell_submit(**kwargs)
    print("{:<{}}: job {} ...".format(name, longest, jid), end='')
    result = multyvac.get(jid).get_result().strip('\n')
    print(" result [{}]".format(result))
    if result == "success":
        success += 1
    else:
        failure += 1

print("{} pass / {} fail".format(success, failure))
if failure > 0:
    sys.exit(1)
示例#4
0
        "cmd": 'echo "success" > /tmp/out',
        "_result_source": "file:/tmp/out",
    },
    "stdin": {
        "cmd": 'cat',
        "_stdin": "success",
    },
}

longest = 0
for name in jobs.keys():
    if len(name) > longest:
        longest = len(name)

success = 0
failure = 0

for (name, kwargs) in jobs.items():
    jid = multyvac.shell_submit(**kwargs)
    print("{:<{}}: job {} ...".format(name, longest, jid), end='')
    result = multyvac.get(jid).get_result().strip('\n')
    print(" result [{}]".format(result))
    if result == "success":
        success += 1
    else:
        failure += 1

print("{} pass / {} fail".format(success, failure))
if failure > 0:
    sys.exit(1)