net/dump: init
This adds netdump, a library which dumps the network configuration of a
Linux host via netlink and generates a Net specification from it.
Change-Id: I78007df1da4fbf24ba9128eb2e966df0dea9274e
Reviewed-on: https://review.monogon.dev/c/monogon/+/1231
Reviewed-by: Serge Bazanski <serge@monogon.tech>
Tested-by: Leopold Schabel <leo@monogon.tech>
diff --git a/net/dump/BUILD.bazel b/net/dump/BUILD.bazel
new file mode 100644
index 0000000..59a8707
--- /dev/null
+++ b/net/dump/BUILD.bazel
@@ -0,0 +1,16 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+ name = "dump",
+ srcs = [
+ "hwaddr_compat.go",
+ "netdump.go",
+ ],
+ importpath = "source.monogon.dev/net/dump",
+ visibility = ["//visibility:public"],
+ deps = [
+ "//net/proto",
+ "@com_github_vishvananda_netlink//:netlink",
+ "@org_golang_x_sys//unix",
+ ],
+)