Add networkctl fact #573
Reference in New Issue
Block a user
Delete Branch "benvin/networkctl-fact"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Hosts running systemd-networkd expose link, address, route and DNS state only through
networkctl, so none of it is visible in PuppetDB for querying or reporting.networkctlfact fromnetworkctl --json=short, keyed by interface namenetworkctland a running networkd (/run/systemd/netif)networkctl --json=shortis unsupported on systemd 239/252 (AlmaLinux 8/9, most of the estate); it errors, output is empty, fact is silently nil there, so the stated "why" is only met on newer systemd (Fedora/Debian) → confirm the target hosts run a networkctl with --json, or state in the PR body which OSes get the factiface['Name']can be nil, yielding a nil-keyed hash entry → nit:.reject { |i| i['Name'].nil? }or drop ita99be9f→ re-check before merge