util-iso: machine-id gets copied within root-image

This commit is contained in:
Philip 2015-01-10 18:41:22 +01:00
parent 647c7d298e
commit 569f79d1a5

View file

@ -18,7 +18,11 @@ configure_machine_id(){
# set unique machine-id
msg2 "Setting machine-id ..."
chroot $1 dbus-uuidgen --ensure=/etc/machine-id
chroot $1 ln -s /etc/machine-id /var/lib/dbus/machine-id
if [[ -z "$(echo $1 | grep root-image)" ]];then
chroot $1 ln -s /etc/machine-id /var/lib/dbus/machine-id
else
chroot $1 cp /etc/machine-id /var/lib/dbus/machine-id
fi
}
# $1: chroot