Merge "Bootstrap worker logs with zuul information"
diff --git a/zuul/ansible/library/zuul_log.py b/zuul/ansible/library/zuul_log.py
index 8978275..2072bc9 100644
--- a/zuul/ansible/library/zuul_log.py
+++ b/zuul/ansible/library/zuul_log.py
@@ -34,14 +34,17 @@
def log(msg):
+ if not isinstance(msg, list):
+ msg = [msg]
with Console() as console:
- console.addLine("[Zuul] %s\n" % msg)
+ for line in msg:
+ console.addLine("[Zuul] %s\n" % line)
def main():
module = AnsibleModule(
argument_spec=dict(
- msg=dict(required=True),
+ msg=dict(required=True, type='raw'),
)
)
diff --git a/zuul/launcher/ansiblelaunchserver.py b/zuul/launcher/ansiblelaunchserver.py
index c13f098..21c2c67 100644
--- a/zuul/launcher/ansiblelaunchserver.py
+++ b/zuul/launcher/ansiblelaunchserver.py
@@ -1032,6 +1032,13 @@
state='directory'))
main_block.append(task)
+ msg = [
+ "Launched by %s" % self.manager_name,
+ "Building remotely on %s in workspace %s" % (
+ self.name, parameters['WORKSPACE'])]
+ task = dict(zuul_log=dict(msg=msg))
+ main_block.append(task)
+
for builder in jjb_job.get('builders', []):
if 'shell' in builder:
main_block.extend(