From f6430df250fb9e119e566a38c1ffa661d64021f5 Mon Sep 17 00:00:00 2001 From: Sage Weil Date: Thu, 29 Aug 2013 11:46:38 -0700 Subject: [PATCH] run: write info.yaml on job start Include basic metadata bout the job. Signed-off-by: Sage Weil --- teuthology/run.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/teuthology/run.py b/teuthology/run.py index 5ac0eaa796..f3e44abae9 100644 --- a/teuthology/run.py +++ b/teuthology/run.py @@ -130,6 +130,14 @@ def main(): ctx.owner = get_user() write_initial_metadata(ctx) + if ctx.archive is not None: + info = {} + info['pid'] = os.getpid(); + info['description'] = ctx.description; + info['run'] = ctx.name; + info['owner'] = ctx.owner; + with file(os.path.join(ctx.archive, 'info.yaml'), 'w') as f: + yaml.safe_dump(info, f, default_flow_style=False) log.debug('test') raise RuntimeError('hi there') -- 2.39.5