[YOCTO #14952] -- https://bugzilla.yoctoproject.org/show_bug.cgi?id=14952
Help avoid contention by adding a check to ensure files and directories
are at least 60s old when attempting to delete them from the trashdir,
in case bitbake or another process is still actively using them.
Signed-off-by: Trevor Gamblin <tgamblin@baylibre.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
We're seeing issues with the system struggling with resources when
it shouldn't. Ensure the janitor isn't contributing to this by lowering
its priority as well as changing ionice.
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
The changes to use variable expansion missed out the clobberdir script. This
patch fixes regressions introduced by that change so data is expanded correctly.
This fix is to move clobberdir from python2 to python3 to resolve unicode data
in python2 and secondly, change the data extraction expansion from
ourconfig["TRASH_DIR"] to utils.getconfig("TRASH_DIR", ourconfig) so that
expansion occurs.
Signed-off-by: Aaron Chan <aaron.chun.yew.chan@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Usage is documented in README and an example, local-example.json is
included.
Also clean up the parameter to loadconfig() as its actually not needed.
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This takes the janitor from the yocto-autobuilder, converts it to python3
and switches it to use the config.json file along with the other code.
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>