MCPcopy Create free account
hub / github.com/archlinux/archinstall / Installer

Class Installer

archinstall/lib/installer.py:75–2125  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

73
74
75class Installer:
76 def __init__(
77 self,
78 target: Path,
79 disk_config: DiskLayoutConfiguration,
80 base_packages: list[str] = [],
81 kernels: list[str] | None = None,
82 silent: bool = False,
83 ):
84 """
85 `Installer()` is the wrapper for most basic installation steps.
86 It also wraps :py:func:`~archinstall.Installer.pacstrap` among other things.
87 """
88 self._base_packages = base_packages or __packages__[:4]
89 self.kernels = kernels or [DEFAULT_KERNEL.value]
90 self._disk_config = disk_config
91
92 self._disk_encryption = disk_config.disk_encryption or DiskEncryption(EncryptionType.NO_ENCRYPTION)
93 self.target: Path = target
94
95 self.init_time = time.strftime('%Y-%m-%d_%H-%M-%S')
96 self._helper_flags: dict[str, str | bool | None] = {
97 'base': False,
98 'bootloader': None,
99 }
100
101 for kernel in self.kernels:
102 self._base_packages.append(kernel)
103
104 # If using accessibility tools in the live environment, append those to the packages list
105 if accessibility_tools_in_use():
106 self._base_packages.extend(__accessibility_packages__)
107
108 self.post_base_install: list[Callable] = [] # type: ignore[type-arg]
109
110 self._modules: list[str] = []
111 self._binaries: list[str] = []
112 self._files: list[str] = []
113
114 # systemd, sd-vconsole and sd-encrypt will be replaced by udev, keymap and encrypt
115 # if HSM is not used to encrypt the root volume. Check mkinitcpio() function for that override.
116 self._hooks: list[str] = [
117 'base',
118 'systemd',
119 'autodetect',
120 'microcode',
121 'modconf',
122 'kms',
123 'keyboard',
124 'sd-vconsole',
125 'block',
126 'filesystems',
127 'fsck',
128 ]
129 self._kernel_params: list[str] = []
130 self._fstab_entries: list[str] = []
131
132 self._zram_enabled = False

Callers 7

perform_installationFunction · 0.90
perform_installationFunction · 0.90
perform_installationFunction · 0.90
perform_installationFunction · 0.90
perform_installationFunction · 0.90
perform_installationFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected