Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
authorAnton Hvornum <anton@hvornum.se>2023-11-21 14:34:30 +0100
committerGitHub <noreply@github.com>2023-11-21 14:34:30 +0100
commitcc806d9c4ce29212c2848c15b4b184feace3e1ac (patch)
tree28f4f1cb3b943d178a07a37369d3133093c51e17 /docs
parente6344f93f7e476d05bbcd642f2ed91fdde545870 (diff)
Started a re-write of the docs (#1967)
* Started a re-write of the docs, using CSV for tables and re-organizing parameter definitions * Added final config options in --config, some have external references which needs to be populated * Forgot to escape a comma * Clarified a note * Added disk configuration and disk encryption docs * Changed way of installing using source and python * Added a 'list script' that lists available scripts. This could be converted to a argparse later. But this does the trick for now. And it's added to ease documentation and listing of available options. * Added a 'Known issues' section, as well as renamed the issues tab * Finished up the known issues section * Added a section regarding --plugin * Added plugin description, tweaked disk_config to the latest changes from #2221 * Added custom-commands docs, and improved some creds and known issue links
Diffstat (limited to 'docs')
-rw-r--r--docs/_static/style.css3
-rw-r--r--docs/_templates/layout.html4
-rw-r--r--docs/archinstall/Application.rst10
-rw-r--r--docs/archinstall/Profile.rst16
-rw-r--r--docs/archinstall/general.rst117
-rw-r--r--docs/archinstall/plugins.rst57
-rw-r--r--docs/cli_parameters/config/config_options.csv24
-rw-r--r--docs/cli_parameters/config/custom_commands.rst22
-rw-r--r--docs/cli_parameters/config/disk_config.rst245
-rw-r--r--docs/cli_parameters/config/disk_encryption.rst19
-rw-r--r--docs/cli_parameters/config/manual_options.csv4
-rw-r--r--docs/examples/binary.rst23
-rw-r--r--docs/examples/python.rst83
-rw-r--r--docs/help/known_issues.rst103
-rw-r--r--docs/help/report_bug.rst (renamed from docs/help/issues.rst)2
-rw-r--r--docs/index.rst38
-rw-r--r--docs/installing/binary.rst52
-rw-r--r--docs/installing/guided.rst425
-rw-r--r--docs/installing/python.rst6
19 files changed, 783 insertions, 470 deletions
diff --git a/docs/_static/style.css b/docs/_static/style.css
new file mode 100644
index 00000000..579fe077
--- /dev/null
+++ b/docs/_static/style.css
@@ -0,0 +1,3 @@
+.wy-nav-content {
+ max-width: none;
+} \ No newline at end of file
diff --git a/docs/_templates/layout.html b/docs/_templates/layout.html
new file mode 100644
index 00000000..b0a44806
--- /dev/null
+++ b/docs/_templates/layout.html
@@ -0,0 +1,4 @@
+{% extends "!layout.html" %}
+{% block extrahead %}
+ <link href="{{ pathto("_static/style.css", True) }}" rel="stylesheet" type="text/css">
+{% endblock %} \ No newline at end of file
diff --git a/docs/archinstall/Application.rst b/docs/archinstall/Application.rst
deleted file mode 100644
index c6eb0d4d..00000000
--- a/docs/archinstall/Application.rst
+++ /dev/null
@@ -1,10 +0,0 @@
-.. _archinstall.Application:
-
-archinstall.Application
-=======================
-
-This class enables access to pre-programmed application configurations.
-This is not to be confused with :ref:`archinstall.Profile` which is for pre-programmed profiles for a wider set of installation sets.
-
-
-.. autofunction:: archinstall.Application
diff --git a/docs/archinstall/Profile.rst b/docs/archinstall/Profile.rst
deleted file mode 100644
index a4c1f3bb..00000000
--- a/docs/archinstall/Profile.rst
+++ /dev/null
@@ -1,16 +0,0 @@
-.. _archinstall.Profile:
-
-archinstall.Profile
-===================
-
-This class enables access to pre-programmed profiles.
-This is not to be confused with :ref:`archinstall.Application` which is for pre-programmed application profiles.
-
-Profiles in general is a set or group of installation steps.
-Where as applications are a specific set of instructions for a very specific application.
-
-An example would be the *(currently fictional)* profile called `database`.
-The profile `database` might contain the application profile `postgresql`.
-And that's the difference between :ref:`archinstall.Profile` and :ref:`archinstall.Application`.
-
-.. autofunction:: archinstall.Profile
diff --git a/docs/archinstall/general.rst b/docs/archinstall/general.rst
deleted file mode 100644
index 970d40f2..00000000
--- a/docs/archinstall/general.rst
+++ /dev/null
@@ -1,117 +0,0 @@
-.. _archinstall.helpers:
-
-.. warning::
- All these helper functions are mostly, if not all, related to outside-installation-instructions. Meaning the calls will affect your current running system - and not touch your installed system.
-
-Profile related helpers
-=======================
-
-.. autofunction:: archinstall.list_profiles
-
-Packages
-========
-
-.. autofunction:: archinstall.find_package
-
-.. autofunction:: archinstall.find_packages
-
-Locale related
-==============
-
-.. autofunction:: archinstall.list_keyboard_languages
-
-.. autofunction:: archinstall.search_keyboard_layout
-
-.. autofunction:: archinstall.set_keyboard_language
-
-..
- autofunction:: archinstall.Installer.set_keyboard_layout
-
-Services
-========
-
-.. autofunction:: archinstall.service_state
-
-Mirrors
-=======
-
-.. autofunction:: archinstall.filter_mirrors_by_region
-
-.. autofunction:: archinstall.add_custom_mirrors
-
-.. autofunction:: archinstall.insert_mirrors
-
-.. autofunction:: archinstall.use_mirrors
-
-.. autofunction:: archinstall.re_rank_mirrors
-
-.. autofunction:: archinstall.list_mirrors
-
-Disk related
-============
-
-.. autofunction:: archinstall.BlockDevice
-
-.. autofunction:: archinstall.Partition
-
-.. autofunction:: archinstall.Filesystem
-
-.. autofunction:: archinstall.device_state
-
-.. autofunction:: archinstall.all_blockdevices
-
-Luks (Disk encryption)
-======================
-
-.. autofunction:: archinstall.luks2
-
-Networking
-==========
-
-.. autofunction:: archinstall.get_hw_addr
-
-.. autofunction:: archinstall.list_interfaces
-
-.. autofunction:: archinstall.check_mirror_reachable
-
-.. autofunction:: archinstall.update_keyring
-
-.. autofunction:: archinstall.enrich_iface_types
-
-.. autofunction:: archinstall.get_interface_from_mac
-
-.. autofunction:: archinstall.wireless_scan
-
-.. autofunction:: archinstall.get_wireless_networks
-
-General
-=======
-
-.. autofunction:: archinstall.log
-
-.. autofunction:: archinstall.locate_binary
-
-.. autofunction:: archinstall.SysCommand
-
-.. autofunction:: archinstall.SysCommandWorker
-
-Exceptions
-==========
-
-.. autofunction:: archinstall.RequirementError
-
-.. autofunction:: archinstall.DiskError
-
-.. autofunction:: archinstall.ProfileError
-
-.. autofunction:: archinstall.SysCallError
-
-.. autofunction:: archinstall.ProfileNotFound
-
-.. autofunction:: archinstall.HardwareIncompatibilityError
-
-.. autofunction:: archinstall.PermissionError
-
-.. autofunction:: archinstall.UserError
-
-.. autofunction:: archinstall.ServiceException
diff --git a/docs/archinstall/plugins.rst b/docs/archinstall/plugins.rst
new file mode 100644
index 00000000..898f9006
--- /dev/null
+++ b/docs/archinstall/plugins.rst
@@ -0,0 +1,57 @@
+.. _archinstall.Plugins:
+
+Python Plugins
+==============
+
+``archinstall`` supports plugins via two methods.
+
+First method is directly via the ``--plugin`` parameter when running as a CLI tool. This will load a specific plugin locally or remotely via a path.
+
+The second method is via Python's built in `plugin discovery`_ using `entry points`_ categorized as ``archinstall.plugin``.
+
+``--plugin`` parameter
+----------------------
+
+The parameter has the benefit of being stored in the ``--conf`` state, meaning when re-running an installation — the plugin will automatically be loaded.
+It's limitation is that it requires an initial path to be known and written and be cumbersome.
+
+Plugin Discovery
+----------------
+
+This method allows for multiple plugins to be loaded with the drawback that they have to be installed beforehand on the system running ``archinstall``.
+This mainly targets those who build their own ISO's and package specific setups for their needs.
+
+
+What's supported?
+-----------------
+
+Currently the documentation for this is scarse. Until that is resolved, the best way to find supported features is to search the source code for `plugin.on_ <https://github.com/search?q=repo%3Aarchlinux%2Farchinstall+%22plugin.on_%22&type=code>`_ as this will give a clear indication of which calls are made to plugins.
+
+How does it work?
+-----------------
+
+``archinstall`` plugins use a discovery-driven approach where plugins are queried for certain functions.
+As an example, if a plugin has the following function:
+
+.. code-block:: python
+
+ def on_pacstrap(*packages):
+ ...
+
+The function :code:`archinstall.Pacman().strap(["some packages"])` is hardcoded to iterate plugins and look for :code:`on_pacstrap` in the plugin.
+If the function exists, :code:`.strap()` will call the plugin's function and replace the initial package list with the result from the plugin.
+
+The best way to document these calls is currently undecided, as it's hard to document this behavior dynamically.
+
+Writing your own?
+-----------------
+
+The simplest way currently is to look at a reference implementation or the community. Two of these are:
+
+* `torxed/archinstall-aur <https://github.com/torxed/archinstall-aur>`_
+* `phisch/archinstall-aur <https://github.com/phisch/archinstall-aur>`_
+
+And search for `plugin.on_ <https://github.com/search?q=repo%3Aarchlinux%2Farchinstall+%22plugin.on_%22&type=code>`_ in the code base to find what ``archinstall`` will look for. PR's are welcome to widen the support for this.
+
+.. _plugin discovery: https://packaging.python.org/en/latest/specifications/entry-points/
+.. _entry points: https://docs.python.org/3/library/importlib.metadata.html#entry-points \ No newline at end of file
diff --git a/docs/cli_parameters/config/config_options.csv b/docs/cli_parameters/config/config_options.csv
new file mode 100644
index 00000000..1861b1e1
--- /dev/null
+++ b/docs/cli_parameters/config/config_options.csv
@@ -0,0 +1,24 @@
+Key,Value(s),Description,Required
+additional-repositories,[ `multilib <https://wiki.archlinux.org/title/Official_repositories#multilib>`_!, `testing <https://wiki.archlinux.org/title/Official_repositories#Testing_repositories>`_ ],Enables one or more of the testing and multilib repositories before proceeding with installation,No
+archinstall-language,`lang <https://github.com/archlinux/archinstall/blob/master/archinstall/locales/languages.json>`__,Sets the TUI language used *(make sure to use the ``lang`` value not the ``abbr``)*,No
+audio_config,`pipewire <https://wiki.archlinux.org/title/PipeWire>`_!, `pulseaudio <https://wiki.archlinux.org/title/PulseAudio>`_,Audioserver to be installed,No
+bootloader,`Systemd-boot <https://wiki.archlinux.org/title/Systemd-boot>`_!, `grub <https://wiki.archlinux.org/title/GRUB>`_,Bootloader to be installed *(grub being mandatory on BIOS machines)*,Yes
+debug,``true``!, ``false``,Enables debug output,No
+disk_config,*Read more under* :ref:`disk config`,Contains the desired disk setup to be used during installation,No
+disk_encryption,*Read more about under* :ref:`disk encryption`,Parameters for disk encryption applied ontop of ``disk_config``,No
+hostname,``str``,A string definining your machines hostname on the network *(defaults to ``archinstall``)*,No
+kernels,[ `linux <https://wiki.archlinux.org/title/Kernel#Officially_supported_kernels>`_!, `linux-hardened <https://wiki.archlinux.org/title/Kernel#Officially_supported_kernels>`_!, `linux-lts <https://wiki.archlinux.org/title/Kernel#Officially_supported_kernels>`_!, `linux-rt <https://wiki.archlinux.org/title/Kernel#Officially_supported_kernels>`_!, `linux-rt-lts <https://wiki.archlinux.org/title/Kernel#Officially_supported_kernels>`_!, `linux-zen <https://wiki.archlinux.org/title/Kernel#Officially_supported_kernels>`_ ],Defines which kernels should be installed and setup in the boot loader options,Yes
+custom-commands,*Read more under* :ref:`custom commands`,Custom commands that will be run post-install chrooted inside the installed system,No
+locale_config,{kb_layout: `lang <https://wiki.archlinux.org/title/Linux_console/Keyboard_configuration>`__!, sys_enc: `Character encoding <https://wiki.archlinux.org/title/Locale>`_!, sys_lang: `locale <https://wiki.archlinux.org/title/Locale>`_},Defines the keyboard key map!, system encoding and system locale,No
+mirror_config,{custom_mirrors: [ https://... ]!, mirror_regions: { "Worldwide": [ "https://geo.mirror.pkgbuild.com/$repo/os/$arch" ] } },Sets various mirrors *(defaults to ISO's ``/etc/pacman.d/mirrors`` if not defined)*,No
+network_config,*`see options under Network Configuration`*,Sets which type of *(if any)* network configuration should be used,No
+no_pkg_lookups,``true``!, ``false``,Disabled package checking against https://archlinux.org/packages/,No
+ntp,``true``!, ``false``,enables or disables `NTP <https://wiki.archlinux.org/title/Network_Time_Protocol_daemon>`_ during installation,No
+offline,``true``!, ``false``,enables or disables certain online checks such as mirror reachability etc,No
+packages,[ <package1>!, <package2>!, ... ],A list of packages to install during installation,No
+parallel downloads,0-∞,sets a given number of paralell downloads to be used by `pacman <https://wiki.archlinux.org/title/Pacman#Enabling_parallel_downloads>`_,No
+profile_config,*`read more under the profiles section`*,Installs a given profile if defined,No
+script,`guided <https://github.com/archlinux/archinstall/blob/master/archinstall/scripts/guided.py>`__! *(default)*!, `minimal <https://github.com/archlinux/archinstall/blob/master/archinstall/scripts/minimal.py>`__!, `only_hdd <https://github.com/archlinux/archinstall/blob/master/archinstall/scripts/only_hdd.py>`_!, `swiss <https://github.com/archlinux/archinstall/blob/master/archinstall/scripts/swiss.py>`_!, `unattended <https://github.com/archlinux/archinstall/blob/master/archinstall/scripts/unattended.py>`_,When used to autorun an installation!, this sets which script to autorun with,No
+silent,``true``!, ``false``,disables or enables user questions using the TUI,No
+swap,``true``!, ``false``,enables or disables swap,No
+timezone,`timezone <https://wiki.archlinux.org/title/System_time#Time_zone>`_,sets a timezone for the installed system,No \ No newline at end of file
diff --git a/docs/cli_parameters/config/custom_commands.rst b/docs/cli_parameters/config/custom_commands.rst
new file mode 100644
index 00000000..c1529020
--- /dev/null
+++ b/docs/cli_parameters/config/custom_commands.rst
@@ -0,0 +1,22 @@
+.. _custom commands:
+
+Custom Commands
+===============
+
+| Custom commands is a configuration entry that allows for executing custom commands post-installation.
+| The commands are executed with `arch-chroot <https://man.archlinux.org/man/extra/arch-install-scripts/arch-chroot.8.en>`_.
+
+The option takes a list of arguments, an example is:
+
+.. code-block:: json
+
+ {
+ "custom-commands": [
+ "hostname new-hostname"
+ ]
+ }
+
+| The following example will set a new hostname in the installed system.
+| The example is just to illustrate that the command is not run in the ISO but inside the installed system after the base system is installed.
+
+More examples can be found in the code repository under `examples/ <https://github.com/archlinux/archinstall/tree/e6344f93f7e476d05bbcd642f2ed91fdde545870/examples>`_ \ No newline at end of file
diff --git a/docs/cli_parameters/config/disk_config.rst b/docs/cli_parameters/config/disk_config.rst
new file mode 100644
index 00000000..ed5f42c1
--- /dev/null
+++ b/docs/cli_parameters/config/disk_config.rst
@@ -0,0 +1,245 @@
+.. _disk config:
+
+Disk Configuration
+==================
+
+There are only three modes in the ``disk_config`` option. They are described in more detail below.
+
+"Leave as is"
+--------------
+
+.. code-block:: json
+
+ {
+ "config_type": "pre_mounted_config",
+ "mountpoint": "/mnt/archinstall"
+ }
+
+This mode will not perform any partitioning what so ever.
+Instead it relies on what's mounted manually by the user under ``/mnt/archinstall``.
+
+Given the following disk example:
+
+.. code-block::
+
+ /mnt/archinstall (/dev/sda2)
+ ├── boot (/dev/sda1)
+ └── home (/dev/sda3)
+
+Runing ``archinstall --conf your.json --silent`` where the above JSON is configured. The disk will be left alone — and a working system will be installed to the above folders and mountpoints will be translated into the installed system.
+
+.. note::
+
+ Some disk layouts can be too complicated to detect, such as RAID setups. Please do report those setups on the `Issue Tracker <https://github.com/archlinux/archinstall>`__ so we can support them.
+
+Best Effort
+-----------
+
+.. warning::
+
+ This mode will wipe data!
+
+.. note::
+
+ Note that this options is similar to the manual partitioning but is generated through the menu system! And the best effort layout might deviate slightly from some wiki guidelines in order to facilitate some optional configurations at a later stage.
+
+.. code-block:: json
+
+ {
+ "disk_config": {
+ "config_type": "default_layout",
+ "device_modifications": [
+ {
+ "device": "/dev/sda",
+ "wipe": true,
+ "partitions": "..."
+ }
+ ]
+ }
+ }
+
+This mode will attempt to configure a sane default layout on the selected disks.
+Based on the chosen filesystem, and potential optional settings for said filesystem — different default layouts will be provided.
+
+Manual Partitioning
+-------------------
+
+.. code-block:: json
+
+ {
+ "disk_config": {
+ "config_type": "manual_partitioning",
+ "device_modifications": [
+ "filesystem struct"
+ ]
+ }
+ }
+
+Manual partitioning is the most complex one of the three. It offers you near endless flexibility of how to partition your disk. It integrates against `pyparted <https://github.com/dcantrell/pyparted>`__ and some control logic in ``archinstall`` that deals with creating things like subvolumes and compression.
+
+Sizes are by default ``sector`` units, but other units are supported.
+
+The options supplied to ``manual_partitioning`` are dictionary definitions, where the following parameters must exist:
+
+.. csv-table:: JSON options
+ :file: ./manual_options.csv
+ :widths: 15, 15, 65, 5
+ :escape: !
+ :header-rows: 1
+
+Each partition definition heavily relies on what filesystem is used.
+Below follow two of the more common filesystems, anything else will best be described by running ``archinstall`` to generate a desired configuration for the desired filesystem type — and copy the relevant parts for permanent configurations.
+
+.. warning::
+
+ Important to note that the units and positions in the examples below — are highly user specific!
+
+FAT32
+^^^^^
+
+.. code-block:: json
+
+ {
+ "btrfs": [],
+ "flags": [
+ "Boot"
+ ],
+ "fs_type": "fat32",
+ "length": {
+ "sector_size": null,
+ "total_size": null,
+ "unit": "B",
+ "value": 99982592
+ },
+ "mount_options": [],
+ "mountpoint": "/boot",
+ "obj_id": "369f31a8-2781-4d6b-96e7-75680552b7c9",
+ "start": {
+ "sector_size": {
+ "sector_size": null,
+ "total_size": null,
+ "unit": "B",
+ "value": 512
+ },
+ "total_size": null,
+ "unit": "sectors",
+ "value": 34
+ },
+ "status": "create",
+ "type": "primary"
+ }
+
+.. note::
+
+ The ``Boot`` flag will make ``archinstall`` automatically set the correct ESP partition GUID if the system is booted with ``EFI`` support. The GUID will then be set to ``C12A7328-F81F-11D2-BA4B-00A0C93EC93B``.
+
+EXT4
+^^^^
+
+.. code-block:: json
+
+ {
+ "btrfs": [],
+ "flags": [],
+ "fs_type": "ext4",
+ "length": {
+ "sector_size": null,
+ "total_size": null,
+ "unit": "B",
+ "value": 15805127360
+ },
+ "mount_options": [],
+ "mountpoint": "/",
+ "obj_id": "3e75d045-21a4-429d-897e-8ec19a006e8b",
+ "start": {
+ "sector_size": {
+ "sector_size": null,
+ "total_size": null,
+ "unit": "B",
+ "value": 512
+ },
+ "total_size": {
+ "sector_size": null,
+ "total_size": null,
+ "unit": "B",
+ "value": 16106127360
+ },
+ "unit": "MB",
+ "value": 301
+ },
+ "status": "create",
+ "type": "primary"
+ }
+
+BTRFS
+^^^^^
+
+The BTRFS filesystem is inherently more complicated, thus the options are a bit more involved.
+This example contains both subvolumes and compression.
+
+.. note::
+
+ Note that the ``"mountpoint": null`` is used for the overall partition, and instead individual subvolumes have mountpoints set.
+
+.. code-block:: json
+
+ {
+ "btrfs": [
+ {
+ "compress": false,
+ "mountpoint": "/",
+ "name": "@",
+ "nodatacow": false
+ },
+ {
+ "compress": false,
+ "mountpoint": "/home",
+ "name": "@home",
+ "nodatacow": false
+ },
+ {
+ "compress": false,
+ "mountpoint": "/var/log",
+ "name": "@log",
+ "nodatacow": false
+ },
+ {
+ "compress": false,
+ "mountpoint": "/var/cache/pacman/pkg",
+ "name": "@pkg",
+ "nodatacow": false
+ },
+ {
+ "compress": false,
+ "mountpoint": "/.snapshots",
+ "name": "@.snapshots",
+ "nodatacow": false
+ }
+ ],
+ "dev_path": null,
+ "flags": [],
+ "fs_type": "btrfs",
+ "mount_options": [
+ "compress=zstd"
+ ],
+ "mountpoint": null,
+ "obj_id": "d712357f-97cc-40f8-a095-24ff244d4539",
+ "size": {
+ "sector_size": {
+ "unit": "B",
+ "value": 512
+ },
+ "unit": "B",
+ "value": 15568207872
+ },
+ "start": {
+ "sector_size": {
+ "unit": "B",
+ "value": 512
+ },
+ "unit": "MiB",
+ "value": 513
+ },
+ "status": "create",
+ "type": "primary"
+ } \ No newline at end of file
diff --git a/docs/cli_parameters/config/disk_encryption.rst b/docs/cli_parameters/config/disk_encryption.rst
new file mode 100644
index 00000000..df2e2fa7
--- /dev/null
+++ b/docs/cli_parameters/config/disk_encryption.rst
@@ -0,0 +1,19 @@
+.. _disk encryption:
+
+Disk Encryption
+===============
+
+Disk encryption consists of a top level entry in the user configuration.
+
+.. code-block:: json
+
+ {
+ "disk_encryption": {
+ "encryption_type": "luks",
+ "partitions": [
+ "d712357f-97cc-40f8-a095-24ff244d4539"
+ ]
+ }
+ }
+
+The ``UID`` in the ``partitions`` list is an internal reference to the ``obj_id`` in the :ref:`disk config` entries. \ No newline at end of file
diff --git a/docs/cli_parameters/config/manual_options.csv b/docs/cli_parameters/config/manual_options.csv
new file mode 100644
index 00000000..2fcc26f0
--- /dev/null
+++ b/docs/cli_parameters/config/manual_options.csv
@@ -0,0 +1,4 @@
+Key,Value(s),Description,Required
+device,``str``,Which block-device to format,yes
+partitions,[ {key: val} ],The data describing the change/addition in a partition,yes
+wipe,``bool``,clear the disk before adding any partitions,No \ No newline at end of file
diff --git a/docs/examples/binary.rst b/docs/examples/binary.rst
deleted file mode 100644
index 51dbd1dd..00000000
--- a/docs/examples/binary.rst
+++ /dev/null
@@ -1,23 +0,0 @@
-.. _examples.binary:
-
-Binary executable
-=================
-
-.. warning:: The binary option is limited and stiff. It's hard to modify or create your own installer-scripts this way unless you compile the source manually. If your usecase needs custom scripts, either use the pypi setup method or you'll need to adjust the PKGBUILD prior to building the arch package.
-
-The binary executable is a standalone compiled version of the library.
-It's compiled using `nuitka <https://nuitka.net/>`_ with the flag `--standalone`.
-
-Executing the binary
---------------------
-
-As an example we'll use the `guided <https://github.com/archlinux/archinstall/blob/master/examples/guided.py>`_ installer.
-To run the `guided` installed, all you have to do *(after installing or compiling the binary)*, is run:
-
-
-.. code-block:: console
-
- ./archinstall guided
-
-As mentioned, the binary is a bit rudimentary and only supports executing whatever is found directly under `./archinstall/examples`.
-Anything else won't be found. This is subject to change in the future to make it a bit more flexible.
diff --git a/docs/examples/python.rst b/docs/examples/python.rst
index b5478fe2..7fb3f6c3 100644
--- a/docs/examples/python.rst
+++ b/docs/examples/python.rst
@@ -4,7 +4,7 @@ Python module
=============
Archinstall supports running in `module mode <https://docs.python.org/3/library/__main__.html>`_.
-The way the library is invoked in module mode is limited to executing scripts under the **example** folder.
+The way the library is invoked in module mode is limited to executing scripts under the `scripts`_ folder.
It's therefore important to place any script or profile you wish to invoke in the examples folder prior to building and installing.
@@ -12,7 +12,7 @@ Pre-requisites
--------------
We'll assume you've followed the :ref:`installing.python.manual` method.
-Before actually installing the library, you will need to place your custom installer-scripts under `./archinstall/examples/` as a python file.
+Before actually installing the library, you will need to place your custom installer-scripts under `scripts`_ as a python file.
More on how you create these in the next section.
@@ -24,36 +24,73 @@ Creating a script
-----------------
Lets create a `test_installer` - installer as an example. This is assuming that the folder `./archinstall` is a git-clone of the main repo.
-We begin by creating `./archinstall/examples/test_installer.py`. The placement here is important later.
+We begin by creating "`scripts`_:code:`/test_installer.py`". The placement here is important later.
-This script can now already be called using `python -m archinstall test_installer` after a successful installation of the library itself.
+This script can now already be called using :code:`python -m archinstall test_installer` after a successful installation of the library itself.
But the script won't do much. So we'll do something simple like list all the hard drives as an example.
-To do this, we'll begin by importing `archinstall` in our `./archinstall/examples/test_installer.py` and call some functions.
+To do this, we'll begin by importing :code:`archinstall` in our "`scripts`_:code:`/test_installer.py`" and call a function whtin ``archinstall``.
.. code-block:: python
import archinstall
- all_drives = archinstall.all_blockdevices(partitions=False)
- print(list(all_drives.keys()))
+ print(archinstall.disk.device_handler.devices)
+
+Now, go ahead and reference the :ref:`installing.python.manual` installation method.
+After runnig ``python -m archinstall test_installer`` it should print something that looks like:
+
+.. code-block:: text
+
+ [
+ BDevice(
+ disk=<parted.disk.Disk object at 0x7fbe17156050>,
+ device_info=_DeviceInfo(
+ model='PC801 NVMe SK hynix 512GB',
+ path=PosixPath('/dev/nvme0n1'),
+ type='nvme',
+ total_size=Size(value=512110190592, unit=<Unit.B: 1>,
+ sector_size=SectorSize(value=512, unit=<Unit.B: 1>)),
+ free_space_regions=[
+ <archinstall.lib.disk.device_model.DeviceGeometry object at 0x7fbe166c4250>,
+ <archinstall.lib.disk.device_model.DeviceGeometry object at 0x7fbe166c4c50>,
+ <archinstall.lib.disk.device_model.DeviceGeometry object at 0x7fbe166c4a10>],
+ sector_size=SectorSize(value=512, unit=<Unit.B: 1>),
+ read_only=False,
+ dirty=False
+ ),
+ partition_infos=[
+ _PartitionInfo(
+ partition=<parted.partition.Partition object at 0x7fbe166c4a90>,
+ name='primary',
+ type=<PartitionType.Primary: 'primary'>,
+ fs_type=<FilesystemType.Fat32: 'fat32'>,
+ path='/dev/nvme0n1p1',
+ start=Size(value=2048, unit=<Unit.sectors: 'sectors'>, sector_size=SectorSize(value=512, unit=<Unit.B: 1>)),
+ length=Size(value=535822336, unit=<Unit.B: 1>, sector_size=SectorSize(value=512, unit=<Unit.B: 1>)),
+ flags=[
+ <PartitionFlag.Boot: 1>,
+ <PartitionFlag.ESP: 18>
+ ],
+ partn=1,
+ partuuid='a26be943-c193-41f4-9930-9341cf5f6b19',
+ uuid='6EE9-2C00',
+ disk=<parted.disk.Disk object at 0x7fbe17156050>,
+ mountpoints=[
+ PosixPath('/boot')
+ ],
+ btrfs_subvol_infos=[]
+ ),
+ _PartitionInfo(...)
+ ]
+ )
+ ]
+
+That means your script is in the right place, and ``archinstall`` is working as intended.
-This should print out a list of drives and some meta-information about them.
-As an example, this will do just fine.
-
-Now, go ahead and install the library either as a user-module or system-wide.
-
-Calling a module
-----------------
-
-Assuming you've followed the example in `Creating a script`_, you can now safely call it with:
-
-.. code-block:: console
-
- python -m archinstall test_installer
+.. note::
-This should now print all available drives on your system.
+ Most calls, including the one above requires `root <https://en.wikipedia.org/wiki/Superuser>`_ privileges.
-.. note::
- This should work on any system, not just Arch Linux based ones. But note that other functions in the library rely heavily on Arch Linux based commands to execute the installation steps. Such as `arch-chroot`.
+.. _scripts: https://github.com/archlinux/archinstall/tree/master/archinstall/scripts \ No newline at end of file
diff --git a/docs/help/known_issues.rst b/docs/help/known_issues.rst
new file mode 100644
index 00000000..2f1f62cb
--- /dev/null
+++ b/docs/help/known_issues.rst
@@ -0,0 +1,103 @@
+.. _help.known_issues:
+
+Known Issues
+============
+
+| Some issues are out of the `archinstall`_ projects scope, and the ones we know of are listed below.
+
+.. _waiting for time sync:
+
+Waiting for time sync `#2144`_
+------------------------------
+
+| The usual root cause of this is the network topology.
+| More specifically `timedatectl show`_ cannot perform a proper time sync against the default servers.
+
+| A *"fix"* for this is mentioned in the issue above.
+| That is to configure ``/etc/systemd/timesyncd.conf`` and restart ``systemd-timesyncd.service``.
+
+.. note::
+
+ A proposal to override the time sync check has been put up for discussion in `#2144`_.
+
+Missing Nvidia Proprietary Driver `#2002`_
+------------------------------------------
+
+| In some instances, the nvidia driver might not have all the nessecary packages installed.
+| This is due to the kernel selection and/or hardware setups requiring additional packages to work properly.
+
+A common workaround is to install the package `linux-headers`_ and `nvidia-dkms`_
+
+ARM, 32bit and other CPU types error out `#1686`_, `#2185`_
+-----------------------------------------------------------
+
+| This is a bit of a catch-all known issue.
+| Officially `x86_64`_ is only supported by Arch Linux.
+| Hence little effort have been put into supporting other platforms.
+
+| In theory, other architectures should work but small quirks might arise.
+
+| PR's are welcome but please be respectful of the delays in merging.
+| Other fixes, issues or features will be prioritized for the above reasons.
+
+Keyring is out of date `#2213`_
+-------------------------------
+
+| Missing key-issues tend to be that the `archlinux-keyring`_ package is out of date, usually as a result of an outdated ISO.
+| There is an attempt from upstream to fix this issue, and it's the `archlinux-keyring-wkd-sync.service`_
+
+| The service starts almost immediately during boot, and if network is not configured in time — the service will fail.
+| Subsequently the ``archinstall`` run might operate on a old keyring despite there being an update service for this.
+
+| There is really no way to reliably over time work around this issue in ``archinstall``.
+| Instead, efforts to the upstream service should be considered the way forward. And/or keys not expiring betwene a sane ammount of ISO's.
+
+.. note::
+
+ The issue can happen on new ISO's too even as little as a few days after release, as some keys might expire right after the keyring is *"burnt in"* to the ISO.
+
+.. note::
+
+ Another common issue relating to the network not being configured, is that time might not be set correctly - resulting in the keyring not being able to update. See :ref:`waiting for time sync`.
+
+AUR packages
+------------
+
+| This is also a catch-all issue.
+| `AUR is unsupported <https://wiki.archlinux.org/title/Arch_User_Repository#Updating_packages>`_, and until that changes we cannot use AUR packages to solve feature requests in ``archinstall``.
+
+| This means that feature requests like supporting filesystems such as `ZFS`_ can not be added, and issues cannot be solved by using AUR packages either.
+
+.. note::
+
+ But in spirit of giving the community options, ``archinstall`` supports :ref:`archinstall.Plugins`, which means you can run ``archinstall --plugin <url>`` and source an AUR plugin.
+
+ `torxed/archinstall-aur <https://github.com/torxed/archinstall-aur>`_ is a reference implementation for plugins:
+
+ .. code-block:: console
+
+ # archinstall --plugin https://archlinux.life/aur-plugin
+
+ `phisch/archinstall-aur <https://github.com/phisch/archinstall-aur>`_ is another alternative:
+
+ .. code-block:: console
+
+ # archinstall --plugin https://raw.githubusercontent.com/phisch/archinstall-aur/master/archinstall-aur.py
+
+ .. warning::
+
+ This will allow for unsupported usage of AUR during installation.
+
+.. _#2213: https://github.com/archlinux/archinstall/issues/2213
+.. _#2185: https://github.com/archlinux/archinstall/issues/2185
+.. _#2144: https://github.com/archlinux/archinstall/issues/2144
+.. _#2002: https://github.com/archlinux/archinstall/issues/2002
+.. _#1686: https://github.com/archlinux/archinstall/issues/1686
+.. _linux-headers: https://archlinux.org/packages/core/x86_64/linux-headers/
+.. _nvidia-dkms: https://archlinux.org/packages/extra/x86_64/nvidia-dkms/
+.. _x86_64: https://wiki.archlinux.org/title/Frequently_asked_questions#What_architectures_does_Arch_support?
+.. _archlinux-keyring: https://archlinux.org/packages/core/any/archlinux-keyring/
+.. _archlinux-keyring-wkd-sync.service: https://gitlab.archlinux.org/archlinux/archlinux-keyring/-/blob/7e672dad10652a80d1cc575d75cdb46442cd7f96/wkd_sync/archlinux-keyring-wkd-sync.service.in
+.. _ZFS: https://aur.archlinux.org/packages/zfs-linux
+.. _archinstall: https://github.com/archlinux/archinstall/
+.. _timedatectl show: https://github.com/archlinux/archinstall/blob/e6344f93f7e476d05bbcd642f2ed91fdde545870/archinstall/lib/installer.py#L136 \ No newline at end of file
diff --git a/docs/help/issues.rst b/docs/help/report_bug.rst
index 7d690b65..bd0ac50a 100644
--- a/docs/help/issues.rst
+++ b/docs/help/report_bug.rst
@@ -1,6 +1,6 @@
.. _help.issues:
-Issue tracker & bugs
+Report Issues & Bugs
====================
Issues and bugs should be reported over at `https://github.com/archlinux/archinstall/issues <https://github.com/Torxed/archinstall/issues>`_.
diff --git a/docs/index.rst b/docs/index.rst
index a76a58d6..6a81bbb0 100644
--- a/docs/index.rst
+++ b/docs/index.rst
@@ -8,17 +8,15 @@ archinstall Documentation
Some of the features of Archinstall are:
-* **No external dependencies or installation requirements.** Runs without any external requirements or installation processes.
-
* **Context friendly.** The library always executes calls in sequential order to ensure installation-steps don't overlap or execute in the wrong order. It also supports *(and uses)* context wrappers to ensure cleanup and final tasks such as ``mkinitcpio`` are called when needed.
-* **Full transparency** Logs and insights can be found at ``/var/log/archinstall`` both in the live ISO and the installed system.
+* **Full transparency** Logs and insights can be found at ``/var/log/archinstall`` both in the live ISO and partially on the installed system.
* **Accessibility friendly** Archinstall works with ``espeakup`` and other accessibility tools thanks to the use of a TUI.
.. toctree::
- :maxdepth: 3
- :caption: Running the installer
+ :maxdepth: 1
+ :caption: Running Archinstall
installing/guided
@@ -26,8 +24,9 @@ Some of the features of Archinstall are:
:maxdepth: 3
:caption: Getting help
+ help/known_issues
+ help/report_bug
help/discord
- help/issues
.. toctree::
:maxdepth: 3
@@ -35,35 +34,10 @@ Some of the features of Archinstall are:
installing/python
examples/python
-
-.. toctree::
- :maxdepth: 3
- :caption: Archinstall as a binary
-
- installing/binary
- examples/binary
-..
- examples/scripting
-
-..
- .. toctree::
- :maxdepth: 3
- :caption: Programming Guide
-
-..
- programming_guide/requirements
- programming_guide/basic_concept
+ archinstall/plugins
.. toctree::
:maxdepth: 3
:caption: API Reference
archinstall/Installer
- archinstall/Profile
- archinstall/Application
-
-.. toctree::
- :maxdepth: 3
- :caption: API Helper functions
-
- archinstall/general
diff --git a/docs/installing/binary.rst b/docs/installing/binary.rst
deleted file mode 100644
index eeb9d79d..00000000
--- a/docs/installing/binary.rst
+++ /dev/null
@@ -1,52 +0,0 @@
-.. _installing.binary:
-
-Binary executable
-=================
-
-Archinstall can be compiled into a standalone executable.
-For Arch Linux based systems, there's a package for this called `archinstall <https://archlinux.org/packages/extra/any/archinstall/>`_.
-
-.. warning::
- This is not required if you're running archinstall on a pre-built ISO. The installation is only required if you're creating your own scripted installations.
-
-Using pacman
-------------
-
-Archinstall is on the `official repositories <https://wiki.archlinux.org/index.php/Official_repositories>`_.
-
-.. code-block:: console
-
- sudo pacman -S archinstall
-
-Using PKGBUILD
---------------
-
-The `source <https://github.com/archlinux/archinstall>`_ contains a binary `PKGBUILD <https://github.com/Torxed/archinstall/tree/master/PKGBUILD/archinstall>`_ which can be either copied straight off the website or cloned using :code:`git clone https://github.com/Torxed/archinstall`.
-
-Once you've obtained the `PKGBUILD`, building it is pretty straight forward.
-
-.. code-block:: console
-
- makepkg -s
-
-Which should produce an `archinstall-X.x.z-1.pkg.tar.zst` which can be installed using:
-
-.. code-block:: console
-
- sudo pacman -U archinstall-X.x.z-1.pkg.tar.zst
-
-.. note::
-
- For a complete guide on the build process, please consult the `PKGBUILD on ArchWiki <https://wiki.archlinux.org/index.php/PKGBUILD>`_.
-
-Manual compilation
-------------------
-
-You can compile the source manually without using a custom mirror or the `PKGBUILD` that is shipped.
-Simply clone or download the source, and while standing in the cloned folder `./archinstall`, execute:
-
-.. code-block:: console
-
- nuitka3 --standalone --show-progress archinstall
-
-This requires the `nuitka <https://archlinux.org/packages/community/any/nuitka/>`_ package as well as `python3` to be installed locally.
diff --git a/docs/installing/guided.rst b/docs/installing/guided.rst
index c5e7f1ed..dcedfc10 100644
--- a/docs/installing/guided.rst
+++ b/docs/installing/guided.rst
@@ -3,20 +3,16 @@
Guided installation
===================
-| This is the default script the Arch Linux `Archinstall package <https://archlinux.org/packages/extra/any/archinstall/>`_.
-| It will guide you through a very basic installation of Arch Linux.
+Archinstall ships with a pre-programmed `Guided Installer`_ guiding you through the mandatory steps as well as some optional configurations that can be done.
.. note::
- There are other scripts and they can be invoked by executing `archinstall <script>` *(without .py)*. To see a complete list of scripts, see the source code directory `examples/ <https://github.com/archlinux/archinstall/tree/master/examples>`_
-The installer has three pre-requisites:
- * The latest version of `Arch Linux ISO <https://archlinux.org/download/>`_
- * A physical or virtual machine to install on
- * A `working internet connection <https://wiki.archlinux.org/title/installation_guide#Connect_to_the_internet>`_ prior to running archinstall
+ Other pre-programmed scripts can be invoked by executing :code:`archinstall <script>` *(without .py)*. To see a complete list of scripts, run :code:`archinstall --script list` or check the source code `scripts`_ directory.
.. note::
- A basic understanding of machines, ISO-files and command line arguments are needed.
- Please read the official `Arch Linux Wiki <https://wiki.archlinux.org/>`_ to learn more about your future operating system.
+
+ It's recommended to run ``archinstall`` from the official Arch Linux ISO.
+
.. warning::
The installer will not configure WiFi before the installation begins. You need to read up on `Arch Linux networking <https://wiki.archlinux.org/index.php/Network_configuration>`_ before you continue.
@@ -28,128 +24,216 @@ To start the installer, run the following in the latest Arch Linux ISO:
.. code-block:: sh
- archinstall --script guided
+ archinstall
-| The ``--script guided`` argument is optional as it's the default behavior.
-| But this will use our most guided installation and if you skip all the option steps it will install a minimal Arch Linux experience.
+Since the `Guided Installer`_ is the default script, this is the equvilant of running :code:`archinstall guided`
-Installing directly from a configuration file
----------------------------------------------
-| The guided installation also supports installing with pre-configured answers to all the guided steps.
-| This can be a quick and convenient way to re-run one or several installations.
-|
-| After each successful installation a pre-configured configuration will be found at ``/var/log/archinstall`` both on the live media and the installed system.
+The guided installation also supports installing with pre-configured answers to all the guided steps. This can be a quick and convenient way to re-run one or several installations.
-There are three different configuration files, all of which are optional.
- * ``--config`` that deals with the general configuration of language and which profiles to use.
- * ``--creds`` which takes any ``superuser``, ``user`` or ``root`` account data.
- * ``--disk_layouts`` for defining the desired partition strategy on the selected ``"harddrives"`` in ``--config``.
+There are two configuration files, both are optional.
-.. note::
- You can always get the latest options with ``archinstall --dry-run``, but edit the following json according to your needs.
- Save the configuration as a ``.json`` file. Archinstall can source it via a local or remote path (URL)
+``--config``
+------------
-.. code-block:: json
+This parameter takes a local or remote :code:`.json` file as argument and contains the overall configuration and menu answers for the guided installer.
- {
- "audio_config": {"audio": "pipewire"},
- "bootloader": "systemd-bootctl",
- "custom-commands": [
- "cd /home/devel; git clone https://aur.archlinux.org/paru.git",
- "chown -R devel:devel /home/devel/paru",
- "usermod -aG docker devel"
- ],
- "filesystem": "btrfs",
- "gfx_driver": "VMware / VirtualBox (open-source)",
- "harddrives": [
- "/dev/nvme0n1"
- ],
- "swap": true,
- "hostname": "development-box",
- "kernels": [
- "linux"
- ],
- "keyboard-language": "us",
- "mirror-region": "Worldwide",
- "network_config": {
- "type": "nm"
- },
- "ntp": true,
- "packages": ["docker", "git", "wget", "zsh"],
- "profile": "gnome",
- "services": ["docker"],
- "sys-encoding": "utf-8",
- "sys-language": "en_US",
- "timezone": "US/Eastern",
- }
+.. note::
+
+ You can always get the latest options for this file with ``archinstall --dry-run``, this executes the guided installer in a safe mode where no permanent actions will be taken on your system but simulate a run and save the configuration to disk.
-To use it, assuming you put it on ``https://domain.lan/config.json``:
+Example usage
+^^^^^^^^^^^^^
.. code-block:: sh
archinstall --config https://domain.lan/config.json
-Options for ``--config``
-------------------------
-
-*(To see which keys are required, scroll to the right in the above table.)*
-
-+----------------------+--------------------------------------------------------+---------------------------------------------------------------------------------------------+-----------------------------------------------+
-| Key | Values | Description | Required |
-| | | | |
-+======================+========================================================+=============================================================================================+===============================================+
-| audio | pipewire/pulseaudio | Audioserver to be installed | No |
-+----------------------+--------------------------------------------------------+---------------------------------------------------------------------------------------------+-----------------------------------------------+
-| bootloader | systemd-bootctl/grub-install | Bootloader to be installed *(grub being mandatory on BIOS machines)* | Yes |
-+----------------------+--------------------------------------------------------+---------------------------------------------------------------------------------------------+-----------------------------------------------+
-| custom-commands | [ <command1>, <command2>, ...] | Custom commands to be run post install | No |
-+----------------------+--------------------------------------------------------+---------------------------------------------------------------------------------------------+-----------------------------------------------+
-| gfx_driver | - "VMware / VirtualBox (open-source)" | Graphics Drivers to install | No |
-| | - "Nvidia" | | |
-| | - "Intel (open-source)" | | |
-| | - "AMD / ATI (open-source)" | | |
-| | - "All open-source (default)" | | |
-+----------------------+--------------------------------------------------------+---------------------------------------------------------------------------------------------+-----------------------------------------------+
-| harddrives | [ <path of device>, <path of second device>, ... } | Multiple paths to block devices to be formatted | No[1] |
-+----------------------+--------------------------------------------------------+---------------------------------------------------------------------------------------------+-----------------------------------------------+
-| hostname | any | Hostname of machine after installation. Default will be ``archinstall`` | No |
-+----------------------+--------------------------------------------------------+---------------------------------------------------------------------------------------------+-----------------------------------------------+
-| kernels | [ "kernel1", "kernel2"] | List of kernels to install eg: linux, linux-lts, linux-zen etc | At least 1 |
-+----------------------+--------------------------------------------------------+---------------------------------------------------------------------------------------------+-----------------------------------------------+
-| keyboard-layout | Any valid layout given by ``localectl list-keymaps`` | eg: ``us``, ``de`` or ``de-latin1`` etc. Defaults to ``us`` | No |
-+----------------------+--------------------------------------------------------+---------------------------------------------------------------------------------------------+-----------------------------------------------+
-| mirror-region | | {"<Region Name>": { "Mirror URL": True/False}, ..} | | Defaults to automatic selection. | No |
-| | | "Worldwide" or "Sweden" | | Either takes a dictionary structure of region and a given set of mirrors. | |
-| | | | Or just a region and archinstall will source any mirrors for that region automatically | |
-+----------------------+--------------------------------------------------------+---------------------------------------------------------------------------------------------+-----------------------------------------------+
-| nic | | { type: <ISO|NM|MANUAL> } | | Type must be one of ISO, NM, MANUAL. ISO will copy the configuration on the image, | No |
-| | | | | NM configures NetworkManager and MANUAL allows to specify custom configuration | |
-| | | { "iface": "eth0"} | | Only MANUAL: name of the interface | |
-| | | { "dhcp": <boolean>} | | Only MANUAL: If set to true DHCP auto will be setup and all further configs ignored | |
-| | | { "ip": <ip>} | | Only MANUAL: Ip address to set, is MANDATORY | |
-| | | { "gateway": <ip>} | | Only MANUAL: Optional gateway | |
-| | | { "dns": [<ip>]} | | Only MANUAL: Optional DNS servers | |
-+----------------------+--------------------------------------------------------+---------------------------------------------------------------------------------------------+-----------------------------------------------+
-| ntp | <boolean> | Set to true to set-up ntp post install | No |
-+----------------------+--------------------------------------------------------+---------------------------------------------------------------------------------------------+-----------------------------------------------+
-| packages | [ "package1", "package2", ..] | List of packages to install post-installation | No |
-+----------------------+--------------------------------------------------------+---------------------------------------------------------------------------------------------+-----------------------------------------------+
-| profile | Name of the profile to install | Profiles are present in | No |
-| | | `profiles/ <https://github.com/archlinux/archinstall/tree/master/profiles>`_, | |
-| | | use the name of a profile to install it without the ``.py`` extension. | |
-+----------------------+--------------------------------------------------------+---------------------------------------------------------------------------------------------+-----------------------------------------------+
-| services | [ "service1", "service2", ..] | Services to enable post-installation | No |
-+----------------------+--------------------------------------------------------+---------------------------------------------------------------------------------------------+-----------------------------------------------+
-| sys-encoding | "utf-8" | Set to change system encoding post-install, ignored if --advanced flag is not passed | No |
-+----------------------+--------------------------------------------------------+---------------------------------------------------------------------------------------------+-----------------------------------------------+
-| sys-language | "en_US" | Set to change system language post-install, ignored if --advanced flag is not passed | No |
-+----------------------+--------------------------------------------------------+---------------------------------------------------------------------------------------------+-----------------------------------------------+
-| timezone | Timezone to configure in installation | Timezone eg: UTC, Asia/Kolkata etc. Defaults to UTC | No |
-+----------------------+--------------------------------------------------------+---------------------------------------------------------------------------------------------+-----------------------------------------------+
+The contents of :code:`https://domain.lan/config.json`:
+
+.. code-block:: json
+
+ {
+ "__separator__": null,
+ "additional-repositories": [],
+ "archinstall-language": "English",
+ "audio_config": null,
+ "bootloader": "Systemd-boot",
+ "config_version": "2.6.0",
+ "debug": false,
+ "disk_config": {
+ "config_type": "manual_partitioning",
+ "device_modifications": [
+ {
+ "device": "/dev/sda",
+ "partitions": [
+ {
+ "btrfs": [],
+ "flags": [
+ "Boot"
+ ],
+ "fs_type": "fat32",
+ "length": {
+ "sector_size": null,
+ "total_size": null,
+ "unit": "B",
+ "value": 99982592
+ },
+ "mount_options": [],
+ "mountpoint": "/boot",
+ "obj_id": "369f31a8-2781-4d6b-96e7-75680552b7c9",
+ "start": {
+ "sector_size": {
+ "sector_size": null,
+ "total_size": null,
+ "unit": "B",
+ "value": 512
+ },
+ "total_size": null,
+ "unit": "sectors",
+ "value": 34
+ },
+ "status": "create",
+ "type": "primary"
+ },
+ {
+ "btrfs": [],
+ "flags": [],
+ "fs_type": "fat32",
+ "length": {
+ "sector_size": null,
+ "total_size": null,
+ "unit": "B",
+ "value": 100000000
+ },
+ "mount_options": [],
+ "mountpoint": "/efi",
+ "obj_id": "13cf2c96-8b0f-4ade-abaa-c530be589aad",
+ "start": {
+ "sector_size": {
+ "sector_size": null,
+ "total_size": null,
+ "unit": "B",
+ "value": 512
+ },
+ "total_size": {
+ "sector_size": null,
+ "total_size": null,
+ "unit": "B",
+ "value": 16106127360
+ },
+ "unit": "MB",
+ "value": 100
+ },
+ "status": "create",
+ "type": "primary"
+ },
+ {
+ "btrfs": [],
+ "flags": [],
+ "fs_type": "ext4",
+ "length": {
+ "sector_size": null,
+ "total_size": null,
+ "unit": "B",
+ "value": 15805127360
+ },
+ "mount_options": [],
+ "mountpoint": "/",
+ "obj_id": "3e75d045-21a4-429d-897e-8ec19a006e8b",
+ "start": {
+ "sector_size": {
+ "sector_size": null,
+ "total_size": null,
+ "unit": "B",
+ "value": 512
+ },
+ "total_size": {
+ "sector_size": null,
+ "total_size": null,
+ "unit": "B",
+ "value": 16106127360
+ },
+ "unit": "MB",
+ "value": 301
+ },
+ "status": "create",
+ "type": "primary"
+ }
+ ],
+ "wipe": false
+ }
+ ]
+ },
+ "disk_encryption": {
+ "encryption_type": "luks",
+ "partitions": [
+ "3e75d045-21a4-429d-897e-8ec19a006e8b"
+ ]
+ },
+ "hostname": "archlinux",
+ "kernels": [
+ "linux"
+ ],
+ "locale_config": {
+ "kb_layout": "us",
+ "sys_enc": "UTF-8",
+ "sys_lang": "en_US"
+ },
+ "mirror_config": {
+ "custom_mirrors": [],
+ "mirror_regions": {
+ "Sweden": [
+ "https://mirror.osbeck.com/archlinux/$repo/os/$arch",
+ "https://mirror.bahnhof.net/pub/archlinux/$repo/os/$arch",
+ "https://ftp.myrveln.se/pub/linux/archlinux/$repo/os/$arch",
+ "https://ftp.lysator.liu.se/pub/archlinux/$repo/os/$arch",
+ "https://ftp.ludd.ltu.se/mirrors/archlinux/$repo/os/$arch",
+ "https://ftp.acc.umu.se/mirror/archlinux/$repo/os/$arch",
+ "http://mirror.bahnhof.net/pub/archlinux/$repo/os/$arch",
+ "http://ftpmirror.infania.net/mirror/archlinux/$repo/os/$arch",
+ "http://ftp.myrveln.se/pub/linux/archlinux/$repo/os/$arch",
+ "http://ftp.lysator.liu.se/pub/archlinux/$repo/os/$arch",
+ "http://ftp.acc.umu.se/mirror/archlinux/$repo/os/$arch"
+ ]
+ }
+ },
+ "network_config": {},
+ "no_pkg_lookups": false,
+ "ntp": true,
+ "offline": false,
+ "packages": [],
+ "parallel downloads": 0,
+ "profile_config": null,
+ "save_config": null,
+ "script": "guided",
+ "silent": false,
+ "swap": true,
+ "timezone": "UTC",
+ "version": "2.6.0"
+ }
+
+``--config`` options
+^^^^^^^^^^^^^^^^^^^^
+
+.. warning::
+
+ All key and value entries must conform to the JSON standard. Below is human readable examples with links, effectively breaking the syntax. Adapt the descriptions below to suit your needs and the JSON format.
+
+.. note::
+
+ Scroll to the right in the table to see required options.
+
+.. csv-table:: JSON options
+ :file: ../cli_parameters/config/config_options.csv
+ :widths: 15, 40, 40, 5
+ :escape: !
+ :header-rows: 1
+.. I'd like to keep this note, as this is the intended behavior of archinstall.
.. note::
- [1] If no entries are found in ``harddrives``, archinstall guided installation will use whatever is mounted currently under ``/mnt/archinstall``.
+
+ If no entries are found in ``disk_config``, archinstall guided installation will use whatever is mounted currently under ``/mnt/archinstall`` without performing any disk operations.
Options for ``--creds``
-----------------------
@@ -163,88 +247,41 @@ Options for ``--creds``
"!root-password" : "SecretSanta2022"
}
-+----------------------+--------------------------------------------------------+--------------------------------------------------------------------------------------+-----------------------------------------------+
-| Key | Values | Description | Required |
-+======================+========================================================+======================================================================================+===============================================+
-| !encryption-password | any | Password to encrypt disk, not encrypted if password not provided | No |
-+----------------------+--------------------------------------------------------+--------------------------------------------------------------------------------------+-----------------------------------------------+
-| !root-password | any | The root account password | No |
-+----------------------+--------------------------------------------------------+--------------------------------------------------------------------------------------+-----------------------------------------------+
-| !users | { "username": "<USERNAME>" | List of regular user credentials, see configuration for reference | No |
-| | "!password": "<PASSWORD>", | | |
-| | "sudo": false|true} | | |
-+----------------------+--------------------------------------------------------+--------------------------------------------------------------------------------------+-----------------------------------------------+
+.. list-table:: --creds options
+ :widths: 25 25 40 10
+ :header-rows: 1
+
+ * - Key
+ - Values
+ - Description
+ - Required
+ * - !encryption-password
+ - ``str``
+ - Password to encrypt disk, not encrypted if password not provided
+ - No
+ * - !root-password
+ - ``str``
+ - The root account password
+ - No
+ * - !users
+ - .. code-block:: json
+
+ {
+ "username": "<USERNAME>",
+ "!password": "<PASSWORD>",
+ "sudo": false
+ }
+ - List of regular user credentials, see configuration for reference
+ - Maybe
+
.. note::
- [1] ``!users`` is optional only if ``!root-password`` was set. ``!users`` will be enforced otherwise and the minimum amount of users with sudo privileges required will be set to 1.
-Options for ``--disk_layouts``
-------------------------------
+ ``!users`` is optional only if ``!root-password`` was set. ``!users`` will be enforced otherwise and the minimum amount of users with sudo privileges required will be set to 1.
.. note::
- | The layout of ``--disk_layouts`` is a bit complicated.
- | It's highly recommended that you generate it using ``--dry-run`` which will simulate an installation, without performing any damaging actions on your machine. *(no formatting is done)*
-
-.. code-block:: json
- {
- "/dev/loop0": {
- "partitions": [
- {
- "boot": true,
- "encrypted": false,
- "filesystem": {
- "format": "fat32"
- },
- "wipe": true,
- "mountpoint": "/boot",
- "size": "513MB",
- "start": "5MB",
- "type": "primary"
- },
- {
- "btrfs": {
- "subvolumes": {
- "@.snapshots": "/.snapshots",
- "@home": "/home",
- "@log": "/var/log",
- "@pkgs": "/var/cache/pacman/pkg"
- }
- },
- "encrypted": true,
- "filesystem": {
- "format": "btrfs"
- },
- "wipe": true,
- "mountpoint": "/",
- "size": "100%",
- "start": "518MB",
- "type": "primary"
- }
- ],
- "wipe": true
- }
- }
+ The key's start with ``!`` because internal log functions will mask any keys starting with explamation from logs and unrestricted configurations.
-| The overall structure is that of ``{ "blockdevice-path" : ...}`` followed by options for that blockdevice.
-| Each partition has it's own settings, and the formatting is executed in order *(top to bottom in the above example)*.
-| Mountpoints is later mounted in order of path traversal, ``/`` before ``/home`` etc.
-
-+----------------------+-----------------------------------------------------+--------------------------------------------------------------------------------------+-----------------------------------------------+
-| Key | Values | Description | Required |
-| | | | |
-+======================+=====================================================+======================================================================================+===============================================+
-| filesystem | { "format": "ext4 / btrfs / fat32 etc." } | Filesystem for root and other partitions | Yes |
-+----------------------+-----------------------------------------------------+--------------------------------------------------------------------------------------+-----------------------------------------------+
-| boot | <bool> | Marks the partition as bootable | No |
-+----------------------+-----------------------------------------------------+--------------------------------------------------------------------------------------+-----------------------------------------------+
-| encrypted | <bool> | Mark the partition for encryption | No |
-+----------------------+-----------------------------------------------------+--------------------------------------------------------------------------------------+-----------------------------------------------+
-| mountpoint | /path | Relative to the inside of the installation, where should the partition be mounted | Yes |
-+----------------------+-----------------------------------------------------+--------------------------------------------------------------------------------------+-----------------------------------------------+
-| start | <size><B, MiB, GiB, %, etc> | The start position of the partition | Yes |
-+----------------------+-----------------------------------------------------+--------------------------------------------------------------------------------------+-----------------------------------------------+
-| type | primary | Only used if MBR and BIOS is used. Marks what kind of partition it is. | No |
-+----------------------+-----------------------------------------------------+--------------------------------------------------------------------------------------+-----------------------------------------------+
-| btrfs | { "subvolumes": {"subvolume": "mountpoint"}} | Support for btrfs subvolumes for a given partition | No |
-+----------------------+-----------------------------------------------------+--------------------------------------------------------------------------------------+-----------------------------------------------+
+.. _scripts: https://github.com/archlinux/archinstall/tree/master/archinstall/scripts
+.. _Guided Installer: https://github.com/archlinux/archinstall/blob/master/archinstall/scripts/guided.py \ No newline at end of file
diff --git a/docs/installing/python.rst b/docs/installing/python.rst
index cf4f7882..edd55138 100644
--- a/docs/installing/python.rst
+++ b/docs/installing/python.rst
@@ -50,8 +50,10 @@ You can either move the folder into your project and simply do
import archinstall
-Or you can use `setuptools <https://pypi.org/project/setuptools/>`_ to install it into the module path.
+Or you can PyPa's `build <https://github.com/pypa/build>`_ and `installer <https://github.com/pypa/installer>`_ to install it into pythons module path.
.. code-block:: console
- sudo python setup.py install \ No newline at end of file
+ $ cd archinstall
+ $ python -m build .
+ $ python -m installer dist/*.whl \ No newline at end of file