commit 39dd2678cf845fdd69e277f998afbbaf9345e88c
parent 7839b4ddbda6662741487fe65138a5e89ff10506
Author: Jan Pobrislo <ccx@webprojekty.cz>
Date: Mon, 1 Aug 2022 05:57:47 +0200
Add mdevd
Diffstat:
4 files changed, 66 insertions(+), 18 deletions(-)
diff --git a/config.aat b/config.aat
@@ -12,11 +12,11 @@ getty_max=8
static_ip=[
iface ip cidr
|#lo 127.0.0.1 8
-eth0 192.168.16.23 24
+eth0 10.70.145.187 25
]
static_route=[
iface spec
-eth0 0.0.0.0/0 via 192.168.16.1
+eth0 default via 10.70.145.129
]
|}
diff --git a/fs b/fs
@@ -10,20 +10,20 @@
/sys
source=sysfs
type=sysfs
- bundles=ok-sysinit
+ bundles=mount-sysinit
down=keep
/proc
source=proc
type=proc
- bundles=ok-sysinit
+ bundles=mount-sysinit
down=keep
/dev
source=dev
type=devtmpfs
options=rw,nosuid
- bundles=ok-sysinit
+ bundles=mount-sysinit
down=keep
# premounted=true
@@ -31,14 +31,14 @@
source=devpts
type=devpts
options=rw,relatime,mode=600,ptmxmode=000
- bundles=ok-sysinit
+ bundles=mount-sysinit
down=keep
/dev/shm
source=shm
type=tmpfs
options=rw,nosuid,nodev,relatime
- bundles=ok-sysinit
+ bundles=mount-sysinit
down=keep
/dev/mqueue
@@ -46,7 +46,7 @@
mkdir=true
type=mqueue
options=rw,nosuid,nodev,noexec
- bundles=ok-sysinit
+ bundles=mount-sysinit
down=keep
#/run
@@ -57,7 +57,7 @@
source=none
type=cgroup2
mkdir=true
- bundles=ok-sysinit
+ bundles=mount-sysinit
# override dependency on rootfs as /run is always rw
dependencies=
diff --git a/s6-rc.aat b/s6-rc.aat
@@ -64,6 +64,13 @@ CN unbound
net-eth0
m644
+/ok-sysinit d m755
+/ok-sysinit/type cN bundle m644
+/ok-sysinit/contents
+CN mount-sysinit
+ dev-coldplug
+m644
+
/ok-mount d m755
/ok-mount/type cN bundle m644
/ok-mount/contents
@@ -249,6 +256,23 @@ CN foreground { modprobe fuse }
foreground { modprobe virtio_net }
m755
+/dev-coldplug d m755
+/dev-coldplug/dependencies
+C mount-dev
+ mount-sys
+ mdevd
+ modules
+m644
+
+/mdevd d m755
+/mdevd/type c longrun m644
+/mdevd/dependencies c mount-dev m644
+/mdevd/notification-fd c 3 m644
+/mdevd/run
+C #!/command/execlineb -P
+ mdevd -D 3
+m755
+
/openrc d m755
/openrc/type cN oneshot m644
/openrc/dependencies
diff --git a/s6-rc.fileset b/s6-rc.fileset
@@ -91,8 +91,8 @@ CN # mount /dev/sda1 on /boot
if { mkdir -p "/boot" }
if -n -t { mount -t "ext2" -o "remount,ro,noatime" "/dev/sda1" "/boot" }
mount -t "ext2" -o "ro,noatime" "/dev/sda1" "/boot"
-/ok-sysinit d m755
-/ok-sysinit/contents
+/mount-sysinit d m755
+/mount-sysinit/contents
CN mount-sys
mount-proc
mount-dev
@@ -102,7 +102,7 @@ CN mount-sys
mount-run-cgroup2
m644
-/ok-sysinit/type cN bundle m644
+/mount-sysinit/type cN bundle m644
/ok-localmount d m755
/ok-localmount/contents
CN rootfs
@@ -138,6 +138,13 @@ CN unbound
net-eth0
m644
+/ok-sysinit d m755
+/ok-sysinit/type cN bundle m644
+/ok-sysinit/contents
+CN mount-sysinit
+ dev-coldplug
+m644
+
/ok-mount d m755
/ok-mount/type cN bundle m644
/ok-mount/contents
@@ -159,10 +166,10 @@ m755
/net-eth0-ip/dependencies r
/net-eth0-ip/up
CN if { ip link set eth0 up }
- if -nt { ip addr add 192.168.16.23/24 dev eth0 }
- pipeline { ip addr show dev eth0 } grep -F -q -e "inet 192.168.16.23/24 "
+ if -nt { ip addr add 10.70.145.187/25 dev eth0 }
+ pipeline { ip addr show dev eth0 } grep -F -q -e "inet 10.70.145.187/25 "
/net-eth0-ip/down
-CN ip addr del 192.168.16.23 dev eth0
+CN ip addr del 10.70.145.187 dev eth0
m755
/net-eth0-route d m755
@@ -173,10 +180,10 @@ C net-eth0-ip
m644
/net-eth0-route/up
CN if { ip link set eth0 up }
- if -nt { ip route add dev eth0 0.0.0.0/0 via 192.168.16.1 }
- pipeline { ip route show dev eth0 0.0.0.0/0 via 192.168.16.1 } grep -q .
+ if -nt { ip route add dev eth0 default via 10.70.145.129 }
+ pipeline { ip route show dev eth0 default via 10.70.145.129 } grep -q .
/net-eth0-route/down
-CN ip route del dev eth0 0.0.0.0/0 via 192.168.16.1
+CN ip route del dev eth0 default via 10.70.145.129
m755
/dhcpcd d m755
@@ -467,6 +474,23 @@ CN foreground { modprobe fuse }
foreground { modprobe virtio_net }
m755
+/dev-coldplug d m755
+/dev-coldplug/dependencies
+C mount-dev
+ mount-sys
+ mdevd
+ modules
+m644
+
+/mdevd d m755
+/mdevd/type c longrun m644
+/mdevd/dependencies c mount-dev m644
+/mdevd/notification-fd c 3 m644
+/mdevd/run
+C #!/command/execlineb -P
+ mdevd -D 3
+m755
+
/openrc d m755
/openrc/type cN oneshot m644
/openrc/dependencies