[machineid] folder needs to be created when not exists

- See #1314
This commit is contained in:
Philip Müller 2020-02-07 10:46:26 +01:00 committed by GitHub
parent 72d742e2f4
commit 97ddd30af4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -54,6 +54,10 @@ def run():
enable_symlink = libcalamares.job.configuration["symlink"]
target_systemd_machineid_file = root_mount_point + "/etc/machine-id"
target_dbus_machineid_file = root_mount_point + "/var/lib/dbus/machine-id"
target_dbus_folder = root_mount_point + "/var/lib/dbus"
if not os.path.exists(target_dbus_folder):
os.mkdir(target_dbus_folder, 0644)
if os.path.exists(target_dbus_machineid_file):
os.remove(target_dbus_machineid_file)