Will Robertson

Open Source contributions: rsyslog

Open Source contributions: rsyslog

About rsyslog

rsyslog is a widely deployed open-source log processing daemon written in C, shipped as the default syslog implementation across most Linux distributions. It supports a large range of inputs, outputs, and processing filters - including the imdocker module which collects log output directly from Docker containers.

imdocker: Add image name to metadata fields

The imdocker module enriches each log line with container metadata: container ID, names, image ID, and labels. While the image ID was already available, SHA hashes are not practical for identifying log sources - you can't easily write a filter rule against a hash you don't have memorised.

This patch adds the container image name and tag to the metadata fields exposed by imdocker, making it straightforward to filter or route logs by image in rsyslog rules. A test case was added to verify the new field alongside the existing metadata tests.

devtools: Pin clang-format version

While preparing the imdocker patch, formatting inconsistencies between development environments caused friction during review - Ubuntu distributions ship different versions of clang-format, and the unversioned clang-format binary resolves to whichever happens to be installed, producing different output on different machines.

A follow-up patch updated devtools/format-code.sh to invoke clang-format-18 explicitly rather than the unversioned binary, eliminating the ambiguity for contributors.

Links

Copyright © Will Robertson 2012 - 2026