In preparation to integrating xdp-forwarder, making the net-vm a net-driver VM. dbus is left, as it will likely be needed in the future for iwd. Signed-off-by: Yureka Lilian <yureka@cyberchaos.dev> --- vm/sys/net/Makefile | 2 +- vm/sys/net/default.nix | 8 +++----- vm/sys/net/file-list.mk | 3 --- .../etc/s6-rc/connman/dependencies.d/dbus | 0 vm/sys/net/image/etc/s6-rc/connman/run | 19 ------------------- vm/sys/net/image/etc/s6-rc/connman/type | 1 - .../net/image/etc/s6-rc/connman/type.license | 2 -- 7 files changed, 4 insertions(+), 31 deletions(-) delete mode 100644 vm/sys/net/image/etc/s6-rc/connman/dependencies.d/dbus delete mode 100644 vm/sys/net/image/etc/s6-rc/connman/run delete mode 100644 vm/sys/net/image/etc/s6-rc/connman/type delete mode 100644 vm/sys/net/image/etc/s6-rc/connman/type.license diff --git a/vm/sys/net/Makefile b/vm/sys/net/Makefile index d71c232..7ad5e5c 100644 --- a/vm/sys/net/Makefile +++ b/vm/sys/net/Makefile @@ -29,7 +29,7 @@ $(vmdir)/netvm/blk/root.img: ../../../scripts/make-gpt.sh ../../../scripts/sfdis build/rootfs.erofs:root:ea21da27-0391-48da-9235-9d2ab2ca7844:root mv $@.tmp $@ -DIRS = dev etc/s6-linux-init/env proc run sys var/lib/connman +DIRS = dev etc/s6-linux-init/env proc run sys BUILD_FILES = build/etc/s6-rc diff --git a/vm/sys/net/default.nix b/vm/sys/net/default.nix index de273e5..ae7fdc5 100644 --- a/vm/sys/net/default.nix +++ b/vm/sys/net/default.nix @@ -7,7 +7,7 @@ pkgsMusl.callPackage ( { lib, stdenvNoCC, nixos, runCommand, writeClosure , erofs-utils, jq, s6-rc, util-linux, xorg -, busybox, connmanMinimal, dbus, execline, kmod, linux_latest, mdevd, nftables +, busybox, dbus, execline, kmod, linux_latest, mdevd, nftables , s6, s6-linux-init }: @@ -51,10 +51,8 @@ let ]; }); - connman = connmanMinimal; - packages = [ - connman dbus execline kmod mdevd s6 s6-linux-init s6-rc + dbus execline kmod mdevd s6 s6-linux-init s6-rc (busybox.override { extraConfig = '' @@ -73,7 +71,7 @@ let # Packages that should be fully linked into /usr, # (not just their bin/* files). - usrPackages = [ connman dbus firmware kernel.modules terminfo ]; + usrPackages = [ dbus firmware kernel.modules terminfo ]; packagesSysroot = runCommand "packages-sysroot" { inherit packages; diff --git a/vm/sys/net/file-list.mk b/vm/sys/net/file-list.mk index 15ccd24..7cc3520 100644 --- a/vm/sys/net/file-list.mk +++ b/vm/sys/net/file-list.mk @@ -20,9 +20,6 @@ LINKS = \ image/var/run S6_RC_FILES = \ - image/etc/s6-rc/connman/dependencies.d/dbus \ - image/etc/s6-rc/connman/run \ - image/etc/s6-rc/connman/type \ image/etc/s6-rc/dbus/notification-fd \ image/etc/s6-rc/dbus/run \ image/etc/s6-rc/dbus/type \ diff --git a/vm/sys/net/image/etc/s6-rc/connman/dependencies.d/dbus b/vm/sys/net/image/etc/s6-rc/connman/dependencies.d/dbus deleted file mode 100644 index e69de29..0000000 diff --git a/vm/sys/net/image/etc/s6-rc/connman/run b/vm/sys/net/image/etc/s6-rc/connman/run deleted file mode 100644 index 058fc17..0000000 --- a/vm/sys/net/image/etc/s6-rc/connman/run +++ /dev/null @@ -1,19 +0,0 @@ -#!/bin/execlineb -P -# SPDX-License-Identifier: EUPL-1.2+ -# SPDX-FileCopyrightText: 2020-2021 Alyssa Ross <hi@alyssa.is> - -if { modprobe af_packet } - -backtick -E HARDWARE_INTERFACES { - pipeline { - find -L /sys/class/net -mindepth 2 -maxdepth 2 -name address -print0 - } - - # Filter out other VMs and the loopback device. - pipeline { xargs -0 grep -iL ^\\(02:01:\\|00:00:00:00:00:00$\\) } - - # Extract the interface names from the address file paths. - awk -F/ "{if (NR > 1) printf \",\"; printf \"%s\", $5}" -} - -connmand -ni $HARDWARE_INTERFACES diff --git a/vm/sys/net/image/etc/s6-rc/connman/type b/vm/sys/net/image/etc/s6-rc/connman/type deleted file mode 100644 index 5883cff..0000000 --- a/vm/sys/net/image/etc/s6-rc/connman/type +++ /dev/null @@ -1 +0,0 @@ -longrun diff --git a/vm/sys/net/image/etc/s6-rc/connman/type.license b/vm/sys/net/image/etc/s6-rc/connman/type.license deleted file mode 100644 index 2b3b032..0000000 --- a/vm/sys/net/image/etc/s6-rc/connman/type.license +++ /dev/null @@ -1,2 +0,0 @@ -SPDX-License-Identifier: CC0-1.0 -SPDX-FileCopyrightText: 2020 Alyssa Ross <hi@alyssa.is> -- 2.51.2