Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/docs/installing
diff options
context:
space:
mode:
authorAnton Hvornum <anton@hvornum.se>2023-11-22 22:45:25 +0100
committerGitHub <noreply@github.com>2023-11-22 22:45:25 +0100
commite28ba953708cee089161a795fb3191cfd5c3d93a (patch)
tree6cc746c2f4d36582d7add747a8f08349ebec9d44 /docs/installing
parentf3b4858a26308b33918226ce18a71de4b3caebb1 (diff)
Restoring back the docs with a commit, as I'm clearly incapable of grasping git's reset/revert features.. (#2249)
Diffstat (limited to 'docs/installing')
-rw-r--r--docs/installing/guided.rst287
-rw-r--r--docs/installing/python.rst59
2 files changed, 346 insertions, 0 deletions
diff --git a/docs/installing/guided.rst b/docs/installing/guided.rst
new file mode 100644
index 00000000..dcedfc10
--- /dev/null
+++ b/docs/installing/guided.rst
@@ -0,0 +1,287 @@
+.. _guided:
+
+Guided installation
+===================
+
+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::
+
+ 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::
+
+ 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.
+
+Running the guided installation
+-------------------------------
+
+To start the installer, run the following in the latest Arch Linux ISO:
+
+.. code-block:: sh
+
+ archinstall
+
+Since the `Guided Installer`_ is the default script, this is the equvilant of running :code:`archinstall guided`
+
+
+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 two configuration files, both are optional.
+
+``--config``
+------------
+
+This parameter takes a local or remote :code:`.json` file as argument and contains the overall configuration and menu answers for the guided installer.
+
+.. 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.
+
+Example usage
+^^^^^^^^^^^^^
+
+.. code-block:: sh
+
+ archinstall --config https://domain.lan/config.json
+
+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::
+
+ 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``
+-----------------------
+
+| Creds is a separate configuration file to separate normal options from more sensitive data like passwords.
+| Below is an example of how to set the root password and below that are description of other values that can be set.
+
+.. code-block:: json
+
+ {
+ "!root-password" : "SecretSanta2022"
+ }
+
+.. 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::
+
+ ``!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 key's start with ``!`` because internal log functions will mask any keys starting with explamation from logs and unrestricted configurations.
+
+.. _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
new file mode 100644
index 00000000..edd55138
--- /dev/null
+++ b/docs/installing/python.rst
@@ -0,0 +1,59 @@
+.. _installing.python:
+
+Python library
+==============
+
+Archinstall ships on `PyPi <https://pypi.org/>`_ as `archinstall <pypi.org/project/archinstall/>`_.
+But the library can be installed manually as well.
+
+.. warning::
+ These steps are not required if you want to use archinstall on the official Arch Linux ISO.
+
+Installing with pacman
+----------------------
+
+Archinstall is on the `official repositories <https://wiki.archlinux.org/index.php/Official_repositories>`_.
+And it will also install archinstall as a python library.
+
+To install both the library and the archinstall script:
+
+.. code-block:: console
+
+ pacman -S archinstall
+
+Alternatively, you can install only the library and not the helper executable using the ``python-archinstall`` package.
+
+Installing with PyPi
+--------------------
+
+The basic concept of PyPi applies using `pip`.
+
+.. code-block:: console
+
+ pip install archinstall
+
+.. _installing.python.manual:
+
+Install using source code
+-------------------------
+
+| You can also install using the source code.
+| For sake of simplicity we will use ``git clone`` in this example.
+
+.. code-block:: console
+
+ git clone https://github.com/archlinux/archinstall
+
+You can either move the folder into your project and simply do
+
+.. code-block:: python
+
+ import archinstall
+
+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
+
+ $ cd archinstall
+ $ python -m build .
+ $ python -m installer dist/*.whl \ No newline at end of file