machine-id: generate a compact version of the uuid

dbus and other actually expect an uuid without hyphens

Reported by:	tijl
MFC After:	3 days
This commit is contained in:
Baptiste Daroussin 2023-02-28 11:31:06 +01:00
parent b2b294f27c
commit a28ccb32bf

View File

@ -23,7 +23,7 @@ machine_id_start()
if [ ! -f ${machine_id_file} ] ; then
startmsg -n "Creating ${machine_id_file} "
t=$(mktemp -t machine-id)
/bin/uuidgen -r -o $t
/bin/uuidgen -r -c -o $t
install -C -o root -g wheel -m ${machine_id_perms} "$t" "${machine_id_file}"
rm -f "$t"
startmsg 'done.'