Commit graph

3 commits

Author SHA1 Message Date
e4aa8ad269 Import go-systemd under its real v22 module path
The systemd service backend imported github.com/coreos/go-systemd while
calling v22-only API, and compiled only because of a local replace onto
the v22 module. Replace directives are ignored outside the main module,
so every consumer had to mirror that replace, and a consumer that also
requires go-systemd/v22 directly could not build at all: Go rejects one
module serving two import paths.

Import github.com/coreos/go-systemd/v22/dbus directly and drop the
replace.
2026-08-11 07:06:14 -05:00
fae43247de Switch unit tests to testify
Bring an administratively down interface up in AddAddress before writing
its addresses and routes. The kernel installs an address's connected
route only while its link is up, so adding a gateway to a down interface
was rejected as unreachable. A link raised this way is part of the
pre-change state AddAddress restores, so it is returned to down on any
path that does not complete.

Also fix the rollback masking its own error: deleting the address it
added takes the default route with it, since that route resolved its
nexthop through the address's connected subnet. The following RouteDel
then answered ESRCH and was reported in place of "aborted operation due
to loss of internet".
2026-07-10 08:52:52 -05:00
50a535bb7f first commit 2026-07-01 15:17:11 -05:00