From 17883fcb9f42f0ac6df21bb1d16fcecca3efa131 Mon Sep 17 00:00:00 2001 From: Anton Hvornum Date: Sun, 6 Dec 2020 23:08:12 +0100 Subject: Check if directory exists before mounting --- archinstall/lib/installer.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'archinstall/lib/installer.py') diff --git a/archinstall/lib/installer.py b/archinstall/lib/installer.py index f06d38ea..7208a7fd 100644 --- a/archinstall/lib/installer.py +++ b/archinstall/lib/installer.py @@ -89,7 +89,10 @@ class Installer(): self.log(f"Submit this zip file as an issue to https://github.com/Torxed/archinstall/issues", level=LOG_LEVELS.Warning) return False - def mount(self, partition, mountpoint): + def mount(self, partition, mountpoint, create_mountpoint=True): + if create_mountpoint and not os.path.isdir(f'{self.mountpoint}/srv/http'): + os.makedirs(f'{self.mountpoint}/srv/http') + partition.mount(f'{self.mountpoint}/srv/http') def post_install_check(self, *args, **kwargs): -- cgit v1.2.3-70-g09d2