index : archinstall32 | |
Archlinux32 installer | gitolite user |
summaryrefslogtreecommitdiff |
author | Andreas Baumann <mail@andreasbaumann.cc> | 2023-04-02 13:50:24 +0200 |
---|---|---|
committer | Andreas Baumann <mail@andreasbaumann.cc> | 2023-04-02 13:50:24 +0200 |
commit | af7ab9833c9f9944874f0162ae0975175ddc628d (patch) | |
tree | c486d4948b5994125f95c8aa1d61a059c1351127 /examples/guided.py | |
parent | 2caad35a885f9be30d5bf79a47f5456f276ae67b (diff) | |
parent | 6e3c6f8863041b54f6d8cf7af37f9719c493eadd (diff) |
-rw-r--r-- | examples/guided.py | 46 |
diff --git a/examples/guided.py b/examples/guided.py index f0b52299..e9240c03 100644 --- a/examples/guided.py +++ b/examples/guided.py @@ -146,14 +146,6 @@ def perform_installation(mountpoint): if partition.size < 0.19: # ~200 MiB in GiB raise archinstall.DiskError(f"The selected /boot partition in use is not large enough to properly install a boot loader. Please resize it to at least 200MiB and re-run the installation.") - # if len(mirrors): - # Certain services might be running that affects the system during installation. - # Currently, only one such service is "reflector.service" which updates /etc/pacman.d/mirrorlist - # We need to wait for it before we continue since we opted in to use a custom mirror/region. - installation.log('Waiting for automatic mirror selection (reflector) to complete.', level=logging.INFO) - while archinstall.service_state('reflector') not in ('dead', 'failed'): - time.sleep(1) - # If we've activated NTP, make sure it's active in the ISO too and # make sure at least one time-sync finishes before we continue with the installation if archinstall.arguments.get('ntp', False): @@ -175,6 +167,22 @@ def perform_installation(mountpoint): installation.log(f"Waiting for timedatectl timesync-status to report a timesync against a server", level=logging.INFO) logged = True time.sleep(1) + + # if len(mirrors): + # Certain services might be running that affects the system during installation. + # Currently, only one such service is "reflector.service" which updates /etc/pacman.d/mirrorlist + # We need to wait for it before we continue since we opted in to use a custom mirror/region. + installation.log('Waiting for automatic mirror selection (reflector) to complete.', level=logging.INFO) + while archinstall.service_state('reflector') not in ('dead', 'failed', 'exited'): + time.sleep(1) + + installation.log('Waiting pacman-init.service to complete.', level=logging.INFO) + while archinstall.service_state('pacman-init') not in ('dead', 'failed', 'exited'): + time.sleep(1) + + installation.log('Waiting Arch Linux keyring sync (archlinux-keyring-wkd-sync) to complete.', level=logging.INFO) + while archinstall.service_state('archlinux-keyring-wkd-sync') not in ('dead', 'failed', 'exited'): + time.sleep(1) # Set mirrors used by pacstrap (outside of installation) if archinstall.arguments.get('mirror-region', None): @@ -279,28 +287,6 @@ if archinstall.arguments.get('skip-mirror-check', False) is False and archinstal archinstall.log(f"Arch Linux mirrors are not reachable. Please check your internet connection and the log file '{log_file}'.", level=logging.INFO, fg="red") exit(1) -if not archinstall.arguments.get('offline'): - latest_version_archlinux_keyring = max([k.pkg_version for k in archinstall.find_package('archlinux-keyring')]) - - # For now always update for now, we don't have the coresponding package search API - if archinstall.arguments.get('skip-keyring-update', False) is False: - # Then we update the keyring in the ISO environment - if not archinstall.update_keyring32(): - log_file = os.path.join(archinstall.storage.get('LOG_PATH', None), archinstall.storage.get('LOG_FILE', None)) - archinstall.log(f"Failed to update the Arch32 keyring. Please check your internet connection and the log file '{log_file}'.", level=logging.INFO, fg="red") - exit(1) - - # If we want to check for keyring updates - # and the installed package version is lower than the upstream version - if archinstall.arguments.get('skip-keyring-update', False) is False and \ - archinstall.installed_package('archlinux-keyring').version < latest_version_archlinux_keyring: - - # Then we update the keyring in the ISO environment - if not archinstall.update_keyring(): - log_file = os.path.join(archinstall.storage.get('LOG_PATH', None), archinstall.storage.get('LOG_FILE', None)) - archinstall.log(f"Failed to update the keyring. Please check your internet connection and the log file '{log_file}'.", level=logging.INFO, fg="red") - exit(1) - if not archinstall.arguments.get('silent'): ask_user_questions() |