We found that with BZ https://bugzilla.redhat.com/show_bug.cgi?id=1347821, the hourly docker-cleanup script emits messages to stderr when run, and they are emailed to the root account only. There are logs that show up in the normal log stream, but not from the cron job.
Shouldn't we be running this cron job as a systemd repeating service so that its output will be properly logged through journald?
Peter, running it as a service might be little heavy weight. And I am not sure if service infrastructure allows periodic invocation.
If you are concerned about logging to journal, I think that might be fixable. I found an article talking about using systemd-cat to connect stdout of the program to journal.
(In reply to Vivek Goyal from comment #3)
> Peter, running it as a service might be little heavy weight. And I am not
> sure if service infrastructure allows periodic invocation.
Now sure how that is any heavier weight that the current cron job.
Seems straightforward to do, https://wiki.archlinux.org/index.php/Systemd/Timers#As_a_cron_replacement
> If you are concerned about logging to journal, I think that might be
> fixable. I found an article talking about using systemd-cat to connect
> stdout of the program to journal.
If we just make this a systemd service, we get it for free.
Looks like this was removed.
# rpm -ql docker-common-1.12.5-14.el7.x86_64
# rpm -ql docker-common-1.12.6-16.el7.x86_64
Just to mention that I can see there is already a docker-cleanup systemd timer in docker-1.12.6-16.el7.x86_64
# rpm -ql docker-1.12.6-16.el7.x86_64 | grep -i docker-cleanup
After evaluating this issue, there are no plans to address it further or fix it in an upcoming release. Therefore, it is being closed. If plans change such that this issue will be fixed in an upcoming release, then the bug can be reopened.