This patch exports a new env var for the script, the $TH_RESULT_FILE. If
the launched script writes something into the file name specified in
that env var and if the content of that file doesn't appear to indicate
a successful build, the content of the file is used as summary message
sent back to Zuul.
Originally, this patch attempted to do a similar thing through reading
back stuff from the shell's output log and reporting the last line from
that output, but the two major disadvantages were the inclusion of
timestamps in the log output, and Python's enrichment of the log line
with timestamps. I pondered writing a custom Python's logging.Handler
which simply remembers the last message, but the required changes in
utils.execute_to_log appeared rather messy to my untrained eye.
The main driver behind this change is a need to differentiate from hard
build failures (where we don't get any build artifacts because the build
simply failed) from "mere" test failures. Yes, our (KDE) tests are still
sloppy, and we have a fair amount of broken test still around, which is
why this difference matters to us. The result field in Zuul is more or
less free-form, so this patch does not impose any restrictions about its
format, except the "cannot start with 'SUCCESS'" because that one is
indeed very, very special.
It can be seen in action at http://ci-logs.kde.flaska.net/matrix.html .
Change-Id: I48c29d2566da12b02dcf27a551a058ecc4a303d4
Fetching from git sometimes fails. Log the IP in these cases
so we can investigate the git.o.o logs
Change-Id: I09994cf0706670c44412f5d6da97c67329b40d1b
Turbo-hipster now produces different levels of logs for each job. These
need to be uploaded an in some cases have indexes generated for (eg
swift has no directory listing).
Support for zuul's swift instructions still need updating.
Change-Id: I572c8edfc856bb33998d1cfa0a8d31d274ab1bef
This way the publisher will upload all of the logs and the individual
plugin doesn't need to handle pushing the files.
Change-Id: Ib13fd149828118518a115e473b4bae06d592b28e
Improve the logging for jobs in turbo-hipster so that if something fails
in a plugin (for example the db migration checks) it is logged and uploaded
appropriately.
This causes multiple logs per job.
Change-Id: I01e73ea418defbc0c1abd3b2b4357a816ddf99c3
self.job_name is something like "shell_script-${hostname}-${number}",
and job_arguments doesn't contain anything like a job name, either.
Change-Id: I775609990c740c29016abe89c5dce9ab81ca61b9
The idea is that Zuul passes a lot of useful information, such as the
project name, target branch etc., as ZUUL_* options within the JSON job
data. Let's pass all of these variables to the launched shell script.
This will make it possible to e.g. have a single script that can do the
"right thing" for different projects with distinct build steps, etc.
Change-Id: I6f57ed19e9eef1b987fe2493d409b3ee51af22b6
If a job has failed due to an uncaught exception we should send back
a work_data packet to give zuul more information about the failure.
Change-Id: Ifbf3037134ecd129e1b020bcca193ba092349c29
This lets jobs turn off and exit turbo-hipster once they are done.
This is useful for when using nodepool or when a job leaves the
environment dirty and we can't run more jobs on this worker.
Change-Id: I823be4196a5bf9ca92a14d9caf26163398a9434c