Commit Graph

405 Commits

Author SHA1 Message Date
nl6720 2c00a12c26 configs/releng: add and enable ModemManager
ModemManager's mmcli is the simplest way to connect with WWAN modems.

Mention mmcli in MOTD.

Implements #110.
2021-03-26 17:19:31 +02:00
nl6720 b0ff2a2143 configs/releng: start DHCP client for mobile broadband
Add /etc/systemd/network/20-wwan.network

Related to #110.
2021-03-26 12:28:07 +02:00
nl6720 af4de829e9 configs/releng: rename 20-wireless.network to 20-wlan.network
The file is limited to Wi-Fi (Type=wlan in networkd configuration).
2021-03-26 12:18:08 +02:00
nl6720 4532e23d10 Update configs/releng/airootfs/etc/systemd/network/20-{ethernet,wireless}.network
* Match the device type instead of the interface name.
* Replace DHCP section with DHCPv4/DHCPv6. systemd split the sections.
2021-03-26 11:35:20 +02:00
Alexander Epaneshnikov aa95d36f50 add a sound card firmware 2021-03-14 20:34:43 +00:00
nl6720 c4c4f925a1 Support EROFS
EROFS, like Squashfs, is a read-only file system. It can be used to store airootfs in an image file.
Its advantage is the support for POSIX ACLs. EROFS downside is that currently it only supports LZ4 compression (LZMA support is not yet fully implemented).

A difference from Squashfs is that, EROFS stores change time (ctime) not modification time (mtime). The reverse is true for Squashfs.

Implements https://gitlab.archlinux.org/archlinux/archiso/-/issues/59
2021-03-09 16:25:45 +02:00
David Runge 88f46ee574 releng: Add usbmuxd to list of packages
configs/releng/packages.x86_64:
Add usbmuxd to list of packages, so that users have the option to use iOS devices out-of-the-box for data connection
during installation.

Fixes #99
2021-02-16 21:43:46 +00:00
Kristian Klausen 07a514a143 Remove haveged
haveged was added 8 years ago[1] to increase entropy and presumably to
prevent entropy starvation.

A few things has changed since, most notable:
* the kernel actively tries to add entropy (jitter entropy)[2][3][4][5]
* /dev/random no longer blocks after CRNG initialization[6][7]

[1] d7e790d ("Initialize pacman keyring on bootup")
[2] 3f2dc2798b
[3] 50ee7529ec
[4] https://lore.kernel.org/lkml/alpine.DEB.2.21.1909290010500.2636@nanos.tec.linutronix.de/T/
[5] https://lwn.net/Articles/800509/
[6] 30c08efec8
[7] https://lwn.net/Articles/808575/

Fix #98
2021-02-16 16:33:06 +00:00
nl6720 b522e24979 configs/releng: move locale-gen from customize_airootfs.sh to a pacman hook
This finally removes customize_airootfs.sh from releng.

Fixes https://gitlab.archlinux.org/archlinux/archiso/-/issues/21 .
2021-01-31 11:34:56 +02:00
nl6720 e1e88ba913 config/releng: remove pacman hooks specific to ISO build process from airootfs after they run
This works around https://bugs.archlinux.org/task/49347 .
Leaving the hooks in the airootfs image will result in it being run when pacstrap is run in the live environment. This should not happen as they are intended for the ISO build process only.

Fixes https://gitlab.archlinux.org/archlinux/archiso/-/issues/91 .
2021-01-31 09:55:25 +02:00
nl6720 eda261b408 configs/releng: move the mirror uncommenting sed command from customize_airootfs.sh to a pacman hook
After pacman-mirrorlist is installed, /etc/pacman.d/hooks/uncomment-mirrors.hook will run a sed command which uncomments all Server lines in /etc/pacman.d/mirrorlist.
This brings us another step closer to the complete removal of customize_airootfs.sh.

Related to https://gitlab.archlinux.org/archlinux/archiso/-/issues/21 .
2021-01-27 00:07:45 +02:00
Michael Vorburger d6c3df1495 enable SSH server in releng profile 2021-01-23 15:54:31 +00:00
Michael Vorburger 8df661f9a6 add cloud-init to releng 2021-01-23 15:54:31 +00:00
nl6720 ce1cd106b4 profiledef.sh: Remove www. from archlinux.org
See https://lists.archlinux.org/pipermail/arch-devops/2020-December/000474.html .
2020-12-26 20:11:06 +02:00
nl6720 815a42480d configs/releng/syslinux/archiso_pxe-linux.cfg: add missing /boot to initrd file path
Fixes https://bugs.archlinux.org/task/68803 .
2020-12-01 07:12:31 +02:00
David Runge a1cbcd30bd Fix issues with file ownerships/modes
archiso/mkarchiso:
Make sure to always compare absolute paths in `_make_custom_airootfs()` (as `realpath` is used).
Remove `echo` calls that prevent the setting of actual file ownerships and modes.

configs/releng/profiledef.sh:
Set file mode of /root/.automated_script.sh to 755.

Fixes #82
2020-11-30 21:48:08 +01:00
nl6720 d1a8c2a132 Keep all SYSLINUX files in /syslinux
This gets rid of the duplicate ldlinux.c32 and the useless isolinux.cfg which only points to syslinux.cfg.

Implements https://gitlab.archlinux.org/archlinux/archiso/-/issues/46 .
2020-11-30 16:00:15 +02:00
nl6720 2ccd92348c Allow specifying ownership and mode of custom airootfs files and directories
profiledef.sh can now contain an associative array called file_permissions which can be used to set custom ownership and mode of custom airootfs files. The array's keys contain the path and the value is a colon separated list of owner UID, owner GID and access mode.
For example:

    file_permissions=(
      ["/etc/shadow"]="0:0:400"
    )

This means that mkarchiso now copies airootfs files (and directores) without permissions and anything that should be owned by a user other than root and/or if the mode should be something other than 644 for files and 755 for directories must to be listed in ${file_permission[@]} in profiledef.sh.

Fixes https://gitlab.archlinux.org/archlinux/archiso/-/issues/61 .
2020-11-30 08:46:24 +02:00
Sven-Hendrik Haase 863ebf3456 Use better xz options
Default: 732M
With these options: 675M
2020-11-03 21:17:20 +01:00
nl6720 fd10f4b608 configs/releng/packages.x86_64: add fatresize, gpart and tmux
- fatresize is a utility to resize FAT filesystems using libparted.
- gpart is partition table rescue/guessing tool.
- tmux is a terminal multiplexer. Requested in https://bugs.archlinux.org/task/68252 .
2020-11-01 19:46:32 +02:00
David Runge 850dc6345d Set syslinux bootloader timeout to 15s
configs/releng/syslinux/archiso_sys.cfg:
Set the syslinux bootloader timeout to 15s.
In !97 it has accidentally been set to 1.5s.
2020-10-31 19:12:44 +01:00
David Runge 35cd5c5de5 Set bootloader timeouts to 15s
configs/releng/efiboot/loader/loader.conf,
configs/releng/syslinux/archiso_sys.cfg:

Set the bootloader timeout to 15s, as they have been set to an overly generous 30s in !79.

Fixes #80
2020-10-31 17:53:40 +01:00
Alexander Epaneshnikov 6a777a9d72 fix a typo, add myself in AUTHORS.rst 2020-10-29 16:55:16 +00:00
David Runge 46b741fc8b Fix linter errors in livecd-sound
configs/releng/airootfs/usr/local/bin/livecd-sound:
Replace oldstyle expr with a bash test in `is_numeric()`.

Replace use of `nword()` with call to `wc -w`.

Quote variables in `pick_a_card()`.

Fixes #78
2020-10-29 15:48:51 +01:00
Alexander Epaneshnikov 7f3298a300 implement accessibility support in archiso
this fixes #67
2020-10-29 12:30:37 +00:00
nl6720 cf3445e948 Add modconf to HOOKS array in mkinitcpio.conf
The default mkinitcpio.conf includes modconf in HOOKS.
2020-10-29 13:36:27 +02:00
nl6720 c225f3c8bf configs/releng/packages.x86_64: add squashfs-tools and udftools
- squashfs-tools can be used for system backup. https://wiki.archlinux.org/index.php/Full_system_backup_with_SquashFS
- udftools is needed to format UDF file systems.
2020-10-29 13:34:37 +02:00
David Runge fe0dda99c4 Remove build.sh support from profiles and mkarchiso
configs/{baseline,releng}/build.sh:
Remove `build.sh` scripts. They were deprecated with v47.

archiso/mkarchiso:
Remove all `build.sh` related functionality (i.e. `command_pkglist()`, `command_iso()`, `command_prepare()`,
`command_install()`, `command_init()`, `command_run()`).

Rename `command_build_profile()` to `_build_profile()` to be more in line with the style of the other function naming.

Change `_show_config()` to only print info about the profile and make no more use of parameters.

Remove all help output related to legacy `build.sh` commands.

Fixes #51
2020-10-29 12:32:48 +01:00
nl6720 2d8fd5ae25 Split SYSLINUX configuration into per-kernel configuration files
Slightly simplifies adding boot loader configuration for more kernels.
Unfortunately the INCLUDE statement doesn't support wildcards, so each new file must be manually included in the main syslinux configuration file (syslinux.cfg for baseline and archiso_sys.cfg for releng).
2020-09-27 20:54:11 +03:00
nl6720 6394903160 Use the same file paths in both ISO 9660 and FAT
This allows to use only one systemd-boot configuration file per kernel.
Fixes https://gitlab.archlinux.org/archlinux/archiso/-/issues/44 .
2020-09-27 20:54:11 +03:00
nl6720 fb34c8f153 Do not rename the initramfs image
This is a breaking change. archweb, archiso-manager and various documentation must be updated.

* https://github.com/archlinux/archweb/blob/master/templates/releng/archlinux.ipxe
* https://github.com/pierres/archiso-manager/blob/master/Makefile
2020-09-27 20:54:10 +03:00
nl6720 9405a56915 configs/releng: remove custom reflector.service and use the service provided by the package
archiso specific options are placed in a /etc/systemd/system/reflector.service.d/archiso.conf drop-in.
2020-09-27 19:55:38 +03:00
David Runge 914c43f5d4 Pass profile directory as parameter to mkarchiso
**archiso/mkarchiso**:

Change all override option parameters (i.e. `-A`, `-C`, `-D`, `-L`, `-P` and `-g`) to not directly override the global
variable they are tied to, but instead using an `override_` prefixed variable.

Add `_set_overrides()` to use `override_` prefixed variables (if set) to override those without a prefix.

Remove `-B` (a profile directory) from the list of parameters. The profile directory is now provided as separate
non-option parameter.

Add a call to `_read_profile()`, `_set_overrides()` and `command_build_profile()` to the fallthrough option of the
switch-case checking `command_name` - a non-option parameter to mkarchiso. This effectively provides the possibility to
set the profile directory using a non-option parameter, while still maintaining compatibility to legacy named arguments
used in the configs' `build.sh` scripts.

Extend the warning in regards to legacy `build.sh` based commands to mkarchiso by providing an EOL with archiso v49.

Change the help output to reflect the changes and further elaborate on the legacy commands used by `build.sh` scripts.

Change help output to be ordered alphabetically.

Add help output for `-r` and `-g` options.

Call `_set_overrides()` for legacy commands that accept one or more of the overriden options (i.e. `command_init`,
`command_install`, `command_prepare` and `command_iso`).

Various style fixes.

**configs/{baseline,releng}/build.sh**:

Change call to mkarchiso to use the profile's directory as a named argument instead of an option-argument.

**README.rst**:

Fix documentation on how to call mkarchiso with a profile directory.

Fix wording and ordering of option arguments for run_archiso documentation.

Fixes #52
2020-08-25 19:06:43 +02:00
nl6720 d317d74a79 archiso/mkarchiso: create an empty /etc/machine-id
Fixes https://gitlab.archlinux.org/archlinux/archiso/-/issues/42 .
2020-08-18 21:27:52 +03:00
nl6720 ed20402254 Deprecate build.sh scripts and old mkarchiso commands
Replace build.sh scripts with calls to mkarchiso -B "profiledir" build_profile.

Fixes https://gitlab.archlinux.org/archlinux/archiso/-/issues/37 .
2020-08-17 21:33:20 +03:00
nl6720 a5369be88f archiso/mkarchiso: allow choosing boot modes from profiledef.sh
Boot mode names are:

- bios_syslinux.mbr: SYSLINUX in MBR
- bios.syslinux.eltorito: SYSLINUX (ISOLINUX) via El Torito
- uefi-x64.systemd-boot.esp: systemd-boot on ESP in MBR
- uefi-x64.systemd-boot.eltorito: systemd-boot on ESP via El Torito

It is not yet possible to create an ISO with only El Torito or only MBR boot modes!
2020-08-17 17:14:06 +03:00
nl6720 ade4eee504 archiso/mkarchiso: start preparing a build_profile command
Nothing is implemented yet!

configs/releng/profiledef.sh:
A test profile.
2020-08-17 14:22:36 +03:00
nl6720 d12b587c77 configs/releng/packages.x86_64: replace exfat-utils with exfatprogs
exfatprogs uses the kernel's driver unlike exfat-utils which provides a FUSE driver.
2020-08-11 11:05:44 +03:00
nl6720 c46acc1f93 configs/releng/syslinux/archiso_pxe.cfg: add "checksum" and "verify" boot options
An ISO's checksum and GPG validation primarily matters when PXE booting, so it would be appropriate to enable these options for releng.
They should protect against booting a corrupt image.
2020-08-11 09:52:53 +03:00
nl6720 2be645d75f releng: copy UEFI shell from airootfs instead of the host system
Fixes https://gitlab.archlinux.org/archlinux/archiso/-/issues/35 .
2020-07-30 18:31:25 +03:00
nl6720 a667814cb4 releng: place custom sshd_config in airootfs
Properly track the file instead of modifying it on-the-fly with customize_airootfs.sh.
See https://gitlab.archlinux.org/archlinux/archiso/-/issues/21 .
2020-07-30 15:53:46 +03:00
David Runge 65c3bcaa1a Use latest synced mirrors instead of age
configs/releng/airootfs/etc/systemd/system/reflector.service:
Use the 70 mirrors synced most recently (--latest) instead of a specific time since last sync (--age).
According to FS#67399 using 1hour as sync age is too short, as it sometimes leads to empty list.
2020-07-30 12:06:57 +02:00
nl6720 1f141610c2 Install mkinitcpio-archiso-hooks in airootfs instead of copying the hooks from host 2020-07-30 12:55:12 +03:00
nl6720 aabf517cb1 Build initramfs images only once
Place custom mkinitcpio.conf in airootfs.
Use a custom mkinitcpio preset to specify generated image file path.
2020-07-29 18:19:42 +03:00
nl6720 2eb07a3ce6 Remove unnecessary files from releng's airootfs
configs/releng/airootfs/etc/fstab:
/etc/fstab shipped by the filesystem package has only comments. There is no reason to replace it with an empty file.

configs/releng/airootfs/etc/systemd/system/default.target:
There is no harm in booting to graphical.target. releng does not enable (or even install) any service that has {Required,Wanted}By=graphical.target.
2020-07-29 18:10:25 +03:00
David Runge b18881f511 Add license and basic documentation
LICENSE:
Add GPL-3.0 license.

{{archiso,configs}/*,.editorconfig,.gitlab-ci.yml}:
Add SPDX license identifier.

Makefile:
Add SPDX license identifier.
Install the `run_archiso.sh` script as global executable `run_archiso`.
Use -D and -t flags to install to install files more generically (without a previous call to install the directory).

README.rst:
Add README outlining the project's scope, how to build images from the profiles and how to test.

AUTHORS.rst:
Add list of all direct contributors to the repository.

CONTRIBUTING.rst:
Add basic contribution guidelines, explaining the linter and the license in use.

Closes #7
Closes #3
2020-07-29 14:27:48 +02:00
David Runge 6fd2b1b897 Copy files more generically
configs/*:
Copy all files that do not need a rename generically (not specifying a destination file name).
Do not rename vmlinuz-linux to vmlinuz or vmlinuz.efi (as this serves no purpose and makes the scripts more
complicated).
Do not rename microcode (i.e. {amd,intel}-ucode.img) when copying them and change all boot loader configuration files
that assume a renamed microcode image.
Add note and link to Arch Linux wiki to state why memtest.bin is renamed to memtest.
Copy license files for {amd,intel}-ucode and memtest more generically by placing them into subdirectories with the same
name as the package (to circumenvent overwriting one other).

Closes #33
2020-07-28 12:13:45 +02:00
nl6720 66cfb270d6 Copy /etc/skel/ to user's home from build.sh instead of customize_airootfs.sh
Additionally copy the files to all custom user homes, not just root's.
2020-07-28 11:56:59 +03:00
nl6720 3acf024b72 Set up custom user home directories and their permissions 2020-07-28 11:56:59 +03:00
nl6720 3a6a486904 Deprecate customize_airootfs.sh
Show a deprecation notice if airootfs/root/customize_airootfs.sh is found.
2020-07-28 11:56:58 +03:00