hostnamed: add ACPI and Device Tree chasis detection mechanisms
Heavily "inspired" by systemd.
Testing:
- commented
CHASSIS
, rebooted, runbusctl
(returned emptychassis
). - installed https://gitlab.alpinelinux.org/alpine/aports/-/merge_requests/60604 and rebooted
- run
busctl
again:
oneplus-fajita:~$ busctl get-property org.freedesktop.hostname1 /org/freedesktop/hostname1 org.freedesktop.
hostname1 Chassis
s "handset"
oneplus-fajita:~$ cat /etc/machine-info
PRETTY_HOSTNAME="OnePlus 6T"
#CHASSIS="handset"
HARDWARE_VENDOR="OnePlus"
HARDWARE_MODEL="6T"
Signed-off-by: David Heidelberg david@ixit.cz
Edited by Administrator