Browse Source

archiso 74

master
arcolinuxz 11 months ago
parent
commit
b1c85fdc6a
  1. 116
      archiso/airootfs/etc/ssh/sshd_config
  2. 3
      archiso/airootfs/etc/ssh/sshd_config.d/10-archiso.conf
  3. 44
      archiso/airootfs/etc/systemd/journald.conf
  4. 38
      archiso/airootfs/etc/systemd/logind.conf
  5. 2
      archiso/airootfs/etc/systemd/network.conf.d/ipv6-privacy-extensions.conf
  6. 4
      archiso/airootfs/etc/systemd/network/20-ethernet.network
  7. 4
      archiso/airootfs/etc/systemd/network/20-wlan.network
  8. 4
      archiso/airootfs/etc/systemd/network/20-wwan.network
  9. 6
      archiso/airootfs/etc/systemd/system/etc-pacman.d-gnupg.mount
  10. 1
      archiso/airootfs/etc/systemd/system/sockets.target.wants/pcscd.socket
  11. 13
      archiso/airootfs/root/.automated_script.sh
  12. 4
      archiso/airootfs/root/.gnupg/scdaemon.conf
  13. 9
      archiso/airootfs/usr/local/bin/choose-mirror
  14. 51
      archiso/airootfs/usr/local/bin/livecd-sound
  15. 72
      archiso/grub/grub.cfg
  16. 80
      archiso/grub/loopback.cfg
  17. 5
      archiso/packages.x86_64
  18. 1
      archiso/profiledef.sh

116
archiso/airootfs/etc/ssh/sshd_config

@ -1,116 +0,0 @@
# $OpenBSD: sshd_config,v 1.104 2021/07/02 05:11:21 dtucker Exp $
# This is the sshd server system-wide configuration file. See
# sshd_config(5) for more information.
# This sshd was compiled with PATH=/usr/local/sbin:/usr/local/bin:/usr/bin
# The strategy used for options in the default sshd_config shipped with
# OpenSSH is to specify options with their default value where
# possible, but leave them commented. Uncommented options override the
# default value.
#Port 22
#AddressFamily any
#ListenAddress 0.0.0.0
#ListenAddress ::
#HostKey /etc/ssh/ssh_host_rsa_key
#HostKey /etc/ssh/ssh_host_ecdsa_key
#HostKey /etc/ssh/ssh_host_ed25519_key
# Ciphers and keying
#RekeyLimit default none
# Logging
#SyslogFacility AUTH
#LogLevel INFO
# Authentication:
#LoginGraceTime 2m
PermitRootLogin yes
#StrictModes yes
#MaxAuthTries 6
#MaxSessions 10
#PubkeyAuthentication yes
# The default is to check both .ssh/authorized_keys and .ssh/authorized_keys2
# but this is overridden so installations will only check .ssh/authorized_keys
AuthorizedKeysFile .ssh/authorized_keys
#AuthorizedPrincipalsFile none
#AuthorizedKeysCommand none
#AuthorizedKeysCommandUser nobody
# For this to work you will also need host keys in /etc/ssh/ssh_known_hosts
#HostbasedAuthentication no
# Change to yes if you don't trust ~/.ssh/known_hosts for
# HostbasedAuthentication
#IgnoreUserKnownHosts no
# Don't read the user's ~/.rhosts and ~/.shosts files
#IgnoreRhosts yes
# To disable tunneled clear text passwords, change to no here!
#PasswordAuthentication yes
#PermitEmptyPasswords no
# Change to no to disable s/key passwords
KbdInteractiveAuthentication no
# Kerberos options
#KerberosAuthentication no
#KerberosOrLocalPasswd yes
#KerberosTicketCleanup yes
#KerberosGetAFSToken no
# GSSAPI options
#GSSAPIAuthentication no
#GSSAPICleanupCredentials yes
# Set this to 'yes' to enable PAM authentication, account processing,
# and session processing. If this is enabled, PAM authentication will
# be allowed through the KbdInteractiveAuthentication and
# PasswordAuthentication. Depending on your PAM configuration,
# PAM authentication via KbdInteractiveAuthentication may bypass
# the setting of "PermitRootLogin prohibit-password".
# If you just want the PAM account and session checks to run without
# PAM authentication, then enable this but set PasswordAuthentication
# and KbdInteractiveAuthentication to 'no'.
UsePAM yes
#AllowAgentForwarding yes
#AllowTcpForwarding yes
#GatewayPorts no
#X11Forwarding no
#X11DisplayOffset 10
#X11UseLocalhost yes
#PermitTTY yes
PrintMotd no
#PrintLastLog yes
#TCPKeepAlive yes
#PermitUserEnvironment no
#Compression delayed
#ClientAliveInterval 0
#ClientAliveCountMax 3
#UseDNS no
#PidFile /run/sshd.pid
#MaxStartups 10:30:100
#PermitTunnel no
#ChrootDirectory none
#VersionAddendum none
# no default banner path
#Banner none
# override default of no subsystems
Subsystem sftp /usr/lib/ssh/sftp-server
# Example of overriding settings on a per-user basis
#Match User anoncvs
# X11Forwarding no
# AllowTcpForwarding no
# PermitTTY no
# ForceCommand cvs server

3
archiso/airootfs/etc/ssh/sshd_config.d/10-archiso.conf

@ -0,0 +1,3 @@
# Allow root login using password authentication
PasswordAuthentication yes
PermitRootLogin yes

44
archiso/airootfs/etc/systemd/journald.conf

@ -1,44 +0,0 @@
# This file is part of systemd.
#
# systemd is free software; you can redistribute it and/or modify it
# under the terms of the GNU Lesser General Public License as published by
# the Free Software Foundation; either version 2.1 of the License, or
# (at your option) any later version.
#
# Entries in this file show the compile time defaults.
# You can change settings by editing this file.
# Defaults can be restored by simply deleting this file.
#
# See journald.conf(5) for details.
[Journal]
Storage=volatile
#Compress=yes
#Seal=yes
#SplitMode=uid
#SyncIntervalSec=5m
#RateLimitIntervalSec=30s
#RateLimitBurst=10000
#SystemMaxUse=
#SystemKeepFree=
#SystemMaxFileSize=
#SystemMaxFiles=100
#RuntimeMaxUse=
#RuntimeKeepFree=
#RuntimeMaxFileSize=
#RuntimeMaxFiles=100
#MaxRetentionSec=
#MaxFileSec=1month
#ForwardToSyslog=no
#ForwardToKMsg=no
#ForwardToConsole=no
#ForwardToWall=yes
#TTYPath=/dev/console
#MaxLevelStore=debug
#MaxLevelSyslog=debug
#MaxLevelKMsg=notice
#MaxLevelConsole=info
#MaxLevelWall=emerg
#LineMax=48K
#ReadKMsg=yes
#Audit=yes

38
archiso/airootfs/etc/systemd/logind.conf

@ -1,38 +0,0 @@
# This file is part of systemd.
#
# systemd is free software; you can redistribute it and/or modify it
# under the terms of the GNU Lesser General Public License as published by
# the Free Software Foundation; either version 2.1 of the License, or
# (at your option) any later version.
#
# Entries in this file show the compile time defaults.
# You can change settings by editing this file.
# Defaults can be restored by simply deleting this file.
#
# See logind.conf(5) for details.
[Login]
#NAutoVTs=6
#ReserveVT=6
#KillUserProcesses=no
#KillOnlyUsers=
#KillExcludeUsers=root
#InhibitDelayMaxSec=5
#HandlePowerKey=poweroff
HandleSuspendKey=ignore
HandleHibernateKey=ignore
HandleLidSwitch=ignore
#HandleLidSwitchExternalPower=suspend
#HandleLidSwitchDocked=ignore
#PowerKeyIgnoreInhibited=no
#SuspendKeyIgnoreInhibited=no
#HibernateKeyIgnoreInhibited=no
#LidSwitchIgnoreInhibited=yes
#HoldoffTimeoutSec=30s
#IdleAction=ignore
#IdleActionSec=30min
#RuntimeDirectorySize=10%
#RuntimeDirectoryInodes=400k
#RemoveIPC=yes
#InhibitorsMax=8192
#SessionsMax=8192

2
archiso/airootfs/etc/systemd/network.conf.d/ipv6-privacy-extensions.conf

@ -0,0 +1,2 @@
[Network]
IPv6PrivacyExtensions=yes

4
archiso/airootfs/etc/systemd/network/20-ethernet.network

@ -5,10 +5,12 @@
Name=en* Name=en*
Name=eth* Name=eth*
[Link]
RequiredForOnline=routable
[Network] [Network]
DHCP=yes DHCP=yes
MulticastDNS=yes MulticastDNS=yes
IPv6PrivacyExtensions=yes
# systemd-networkd does not set per-interface-type default route metrics # systemd-networkd does not set per-interface-type default route metrics
# https://github.com/systemd/systemd/issues/17698 # https://github.com/systemd/systemd/issues/17698

4
archiso/airootfs/etc/systemd/network/20-wlan.network

@ -1,10 +1,12 @@
[Match] [Match]
Name=wl* Name=wl*
[Link]
RequiredForOnline=routable
[Network] [Network]
DHCP=yes DHCP=yes
MulticastDNS=yes MulticastDNS=yes
IPv6PrivacyExtensions=yes
# systemd-networkd does not set per-interface-type default route metrics # systemd-networkd does not set per-interface-type default route metrics
# https://github.com/systemd/systemd/issues/17698 # https://github.com/systemd/systemd/issues/17698

4
archiso/airootfs/etc/systemd/network/20-wwan.network

@ -1,9 +1,11 @@
[Match] [Match]
Name=ww* Name=ww*
[Link]
RequiredForOnline=routable
[Network] [Network]
DHCP=yes DHCP=yes
IPv6PrivacyExtensions=yes
# systemd-networkd does not set per-interface-type default route metrics # systemd-networkd does not set per-interface-type default route metrics
# https://github.com/systemd/systemd/issues/17698 # https://github.com/systemd/systemd/issues/17698

6
archiso/airootfs/etc/systemd/system/etc-pacman.d-gnupg.mount

@ -2,7 +2,7 @@
Description=Temporary /etc/pacman.d/gnupg directory Description=Temporary /etc/pacman.d/gnupg directory
[Mount] [Mount]
What=ramfs What=tmpfs
Where=/etc/pacman.d/gnupg Where=/etc/pacman.d/gnupg
Type=ramfs Type=tmpfs
Options=mode=0755 Options=mode=0755,noswap

1
archiso/airootfs/etc/systemd/system/sockets.target.wants/pcscd.socket

@ -0,0 +1 @@
/usr/lib/systemd/system/pcscd.socket

13
archiso/airootfs/root/.automated_script.sh

@ -1,21 +1,22 @@
#!/usr/bin/env bash #!/usr/bin/env bash
script_cmdline () script_cmdline() {
{
local param local param
for param in $(</proc/cmdline); do for param in $(</proc/cmdline); do
case "${param}" in case "${param}" in
script=*) echo "${param#*=}" ; return 0 ;; script=*)
echo "${param#*=}"
return 0
;;
esac esac
done done
} }
automated_script () automated_script() {
{
local script rt local script rt
script="$(script_cmdline)" script="$(script_cmdline)"
if [[ -n "${script}" && ! -x /tmp/startup_script ]]; then if [[ -n "${script}" && ! -x /tmp/startup_script ]]; then
if [[ "${script}" =~ ^((http|https|ftp)://) ]]; then if [[ "${script}" =~ ^((http|https|ftp|tftp)://) ]]; then
# there's no synchronization for network availability before executing this script # there's no synchronization for network availability before executing this script
printf '%s: waiting for network-online.target\n' "$0" printf '%s: waiting for network-online.target\n' "$0"
until systemctl --quiet is-active network-online.target; do until systemctl --quiet is-active network-online.target; do

4
archiso/airootfs/root/.gnupg/scdaemon.conf

@ -0,0 +1,4 @@
disable-ccid
disable-pinpad
pcsc-driver /usr/lib/libpcsclite.so
pcsc-shared

9
archiso/airootfs/usr/local/bin/choose-mirror

@ -6,16 +6,17 @@ get_cmdline() {
local param local param
for param in $(</proc/cmdline); do for param in $(</proc/cmdline); do
case "${param}" in case "${param}" in
$1=*) echo "${param##*=}"; "${1}="*)
echo "${param##*=}"
return 0 return 0
;; ;;
esac esac
done done
} }
mirror=$(get_cmdline mirror) mirror="$(get_cmdline mirror)"
[[ $mirror = auto ]] && mirror=$(get_cmdline archiso_http_srv) [[ "$mirror" == 'auto' ]] && mirror="$(get_cmdline archiso_http_srv)"
[[ $mirror ]] || exit 0 [[ -n "$mirror" ]] || exit 0
mv /etc/pacman.d/mirrorlist /etc/pacman.d/mirrorlist.orig mv /etc/pacman.d/mirrorlist /etc/pacman.d/mirrorlist.orig
cat >/etc/pacman.d/mirrorlist <<EOF cat >/etc/pacman.d/mirrorlist <<EOF

51
archiso/airootfs/usr/local/bin/livecd-sound

@ -19,9 +19,8 @@ bugout () {
stat_fail stat_fail
} }
echo_card_indices() echo_card_indices() {
{ if [[ -f /proc/asound/cards ]]; then
if [ -f /proc/asound/cards ] ; then
sed -n -e's/^[[:space:]]*\([0-7]\)[[:space:]].*/\1/p' /proc/asound/cards sed -n -e's/^[[:space:]]*\([0-7]\)[[:space:]].*/\1/p' /proc/asound/cards
fi fi
} }
@ -34,7 +33,7 @@ echo_card_indices()
# $2 <control> # $2 <control>
# $3 <level> # $3 <level>
unmute_and_set_level() { unmute_and_set_level() {
{ [ "$3" ] &&[ "$2" ] && [ "$1" ] ; } || bugout [[ -n "$3" && -n "$2" && -n "$1" ]] || bugout
systemd-cat -t "livecdsound" printf "Setting: %s on card: %s to %s\n" "$2" "$1" "$3" systemd-cat -t "livecdsound" printf "Setting: %s on card: %s to %s\n" "$2" "$1" "$3"
systemd-cat -t "livecdsound" amixer -c "$1" set "$2" "$3" unmute systemd-cat -t "livecdsound" amixer -c "$1" set "$2" "$3" unmute
return 0 return 0
@ -42,9 +41,8 @@ unmute_and_set_level(){
# $1 <card id> # $1 <card id>
# $2 <control> # $2 <control>
mute_and_zero_level() mute_and_zero_level() {
{ [[ -n "$1" && -n "$2" ]] || bugout
{ [ "$1" ] && [ "$2" ] ; } || bugout
systemd-cat -t "livecdsound" printf "Muting control: %s on card: %s\n" "$2" "$1" systemd-cat -t "livecdsound" printf "Muting control: %s on card: %s\n" "$2" "$1"
systemd-cat -t "livecdsound" amixer -c "$1" set "$2" "0%" mute systemd-cat -t "livecdsound" amixer -c "$1" set "$2" "0%" mute
return 0 return 0
@ -53,17 +51,15 @@ mute_and_zero_level()
# $1 <card ID> # $1 <card ID>
# $2 <control> # $2 <control>
# $3 "on" | "off" # $3 "on" | "off"
switch_control() switch_control() {
{ [[ -n "$3" && -n "$1" ]] || bugout
{ [ "$3" ] && [ "$1" ] ; } || bugout
systemd-cat -t "livecdsound" printf "Switching control: %s on card: %s to %s\n" "$2" "$1" "$3" systemd-cat -t "livecdsound" printf "Switching control: %s on card: %s to %s\n" "$2" "$1" "$3"
systemd-cat -t "livecdsound" amixer -c "$1" set "$2" "$3" systemd-cat -t "livecdsound" amixer -c "$1" set "$2" "$3"
return 0 return 0
} }
# $1 <card ID> # $1 <card ID>
sanify_levels_on_card() sanify_levels_on_card() {
{
unmute_and_set_level "$1" "Front" "80%" unmute_and_set_level "$1" "Front" "80%"
unmute_and_set_level "$1" "Master" "80%" unmute_and_set_level "$1" "Master" "80%"
unmute_and_set_level "$1" "Master Mono" "80%" unmute_and_set_level "$1" "Master Mono" "80%"
@ -134,8 +130,7 @@ sanify_levels_on_card()
} }
# $1 <card ID> | "all" # $1 <card ID> | "all"
sanify_levels() sanify_levels() {
{
local ttsdml_returnstatus=0 local ttsdml_returnstatus=0
local card local card
case "$1" in case "$1" in
@ -148,59 +143,55 @@ sanify_levels()
sanify_levels_on_card "$1" || ttsdml_returnstatus=1 sanify_levels_on_card "$1" || ttsdml_returnstatus=1
;; ;;
esac esac
return $ttsdml_returnstatus return "$ttsdml_returnstatus"
} }
# List all cards that *should* be usable for PCM audio. In my experience, # List all cards that *should* be usable for PCM audio. In my experience,
# the console speaker (handled by the pcsp driver) isn't a suitable playback # the console speaker (handled by the pcsp driver) isn't a suitable playback
# device, so we'll exclude it. # device, so we'll exclude it.
list_non_pcsp_cards() list_non_pcsp_cards() {
{
for card in $(echo_card_indices); do for card in $(echo_card_indices); do
local cardfile="/proc/asound/card${card}/id" local cardfile="/proc/asound/card${card}/id"
if [ -r "$cardfile" ] && [ -f "$cardfile" ] && \ if [[ -r "$cardfile" && -f "$cardfile" && "$(cat "$cardfile")" != pcsp ]]; then
[ "$(cat "$cardfile")" != pcsp ]; then
echo "$card" echo "$card"
fi fi
done done
} }
# Properly initialize the sound card so that we have audio at boot. # Properly initialize the sound card so that we have audio at boot.
unmute_all_cards() unmute_all_cards() {
{
sanify_levels all sanify_levels all
} }
is_numeric() { is_numeric() {
local str=$1 local str="$1"
[[ "$str" =~ ^[0-9]+$ ]] [[ "$str" =~ ^[0-9]+$ ]]
} }
set_default_card() { set_default_card() {
local card=$1 local card="$1"
sed -e "s/%card%/$card/g" </usr/local/share/livecd-sound/asound.conf.in \ sed -e "s/%card%/$card/g" </usr/local/share/livecd-sound/asound.conf.in \
>/etc/asound.conf >/etc/asound.conf
} }
play_on_card() { play_on_card() {
local card=$1 file=$2 local card="$1" file="$2"
aplay -q "-Dplughw:$card,0" "$file" aplay -q "-Dplughw:$card,0" "$file"
} }
# If there are multiple usable sound cards, prompt the user to choose one, # If there are multiple usable sound cards, prompt the user to choose one,
# using auditory feedback. # using auditory feedback.
pick_a_card() pick_a_card() {
{
set -f set -f
usable_cards="$(list_non_pcsp_cards)" usable_cards="$(list_non_pcsp_cards)"
num_usable_cards="$(wc -w <<<"$usable_cards")" num_usable_cards="$(wc -w <<<"$usable_cards")"
if [ "$num_usable_cards" -eq 1 ]; then if (( num_usable_cards == 1 )); then
systemd-cat -t "livecdsound" printf "Only one sound card is detected\n" systemd-cat -t "livecdsound" printf "Only one sound card is detected\n"
exit 0 exit 0
fi fi
systemd-cat -t "livecdsound" printf "multiple sound cards detected\n" systemd-cat -t "livecdsound" printf "multiple sound cards detected\n"
for card in $usable_cards; do for card in "${usable_cards[@]}"; do
if ! is_numeric "$card"; then if ! is_numeric "$card"; then
continue continue
fi fi
@ -208,7 +199,7 @@ pick_a_card()
done done
wait wait
sleep 1 sleep 1
for card in $usable_cards; do for card in "${usable_cards[@]}"; do
if ! is_numeric "$card"; then if ! is_numeric "$card"; then
continue continue
fi fi
@ -221,7 +212,7 @@ pick_a_card()
done done
} }
if [[ $# -eq 0 ]]; then if (( $# == 0 )); then
echo "error: No argument passed." echo "error: No argument passed."
exit 1 exit 1
fi fi

72
archiso/grub/grub.cfg

@ -9,15 +9,19 @@ insmod exfat
insmod udf insmod udf
# Use graphics-mode output # Use graphics-mode output
insmod all_video
insmod font
if loadfont "${prefix}/fonts/unicode.pf2" ; then if loadfont "${prefix}/fonts/unicode.pf2" ; then
insmod all_video
set gfxmode="auto" set gfxmode="auto"
terminal_input console terminal_input console
terminal_output console terminal_output console
fi fi
# Enable serial console # Enable serial console
insmod serial
insmod usbserial_common
insmod usbserial_ftdi
insmod usbserial_pl2303
insmod usbserial_usbdebug
if serial --unit=0 --speed=115200; then if serial --unit=0 --speed=115200; then
terminal_input --append serial terminal_input --append serial
terminal_output --append serial terminal_output --append serial
@ -32,41 +36,62 @@ if [ -z "${ARCHISO_UUID}" ]; then
probe --set ARCHISO_UUID --fs-uuid "${root}" probe --set ARCHISO_UUID --fs-uuid "${root}"
fi fi
# Get a human readable platform identifier
if [ "${grub_platform}" == 'efi' ]; then
archiso_platform='UEFI'
if [ "${grub_cpu}" == 'x86_64' ]; then
archiso_platform="x64 ${archiso_platform}"
elif [ "${grub_cpu}" == 'i386' ]; then
archiso_platform="IA32 ${archiso_platform}"
else
archiso_platform="${grub_cpu} ${archiso_platform}"
fi
elif [ "${grub_platform}" == 'pc' ]; then
archiso_platform='BIOS'
else
archiso_platform="${grub_cpu} ${grub_platform}"
fi
# Set default menu entry # Set default menu entry
default=alci default=alci
timeout=15 timeout=15
timeout_style=menu timeout_style=menu
# GRUB init tune for accessibility
play 600 988 1 1319 4
# Menu entries # Menu entries
menuentry "Alci install medium (x86_64, UEFI)" --class arch --class gnu-linux --class gnu --class os --id 'alci' { menuentry "Alci Linux install medium (%ARCH%, ${archiso_platform})" --class arch --class gnu-linux --class gnu --class os --id 'alci' {
set gfxpayload=keep set gfxpayload=keep
linux /%INSTALL_DIR%/boot/x86_64/vmlinuz-linux archisobasedir=%INSTALL_DIR% archisodevice=UUID=${ARCHISO_UUID} cow_spacesize=4G copytoram=n linux /%INSTALL_DIR%/boot/%ARCH%/vmlinuz-linux archisobasedir=%INSTALL_DIR% archisodevice=UUID=${ARCHISO_UUID}
initrd /%INSTALL_DIR%/boot/intel-ucode.img /%INSTALL_DIR%/boot/amd-ucode.img /%INSTALL_DIR%/boot/x86_64/initramfs-linux.img initrd /%INSTALL_DIR%/boot/intel-ucode.img /%INSTALL_DIR%/boot/amd-ucode.img /%INSTALL_DIR%/boot/%ARCH%/initramfs-linux.img
} }
menuentry "Alci install medium with speakup screen reader (x86_64, UEFI)" --hotkey s --class arch --class gnu-linux --class gnu --class os --id 'alci-accessibility' { menuentry "Alci Linux install medium with speakup screen reader (%ARCH%, ${archiso_platform})" --hotkey s --class arch --class gnu-linux --class gnu --class os --id 'alci-accessibility' {
set gfxpayload=keep set gfxpayload=keep
linux /%INSTALL_DIR%/boot/x86_64/vmlinuz-linux archisobasedir=%INSTALL_DIR% archisodevice=UUID=${ARCHISO_UUID} accessibility=on cow_spacesize=4G copytoram=n linux /%INSTALL_DIR%/boot/%ARCH%/vmlinuz-linux archisobasedir=%INSTALL_DIR% archisodevice=UUID=${ARCHISO_UUID} accessibility=on
initrd /%INSTALL_DIR%/boot/intel-ucode.img /%INSTALL_DIR%/boot/amd-ucode.img /%INSTALL_DIR%/boot/x86_64/initramfs-linux.img initrd /%INSTALL_DIR%/boot/intel-ucode.img /%INSTALL_DIR%/boot/amd-ucode.img /%INSTALL_DIR%/boot/%ARCH%/initramfs-linux.img
} }
if [ "${grub_platform}" == "efi" ]; then
if [ "${grub_cpu}" == "x86_64" ]; then if [ "${grub_platform}" == 'efi' -a "${grub_cpu}" == 'x86_64' -a -f '/boot/memtest86+/memtest.efi' ]; then
menuentry "Run Memtest86+ (RAM test)" --class memtest86 --class memtest --class gnu --class tool { menuentry 'Run Memtest86+ (RAM test)' --class memtest86 --class memtest --class gnu --class tool {
set gfxpayload=800x600,1024x768 set gfxpayload=800x600,1024x768
linux /boot/memtest86+/memtest.efi linux /boot/memtest86+/memtest.efi
} }
menuentry "UEFI Shell" --class efi { fi
insmod chain if [ "${grub_platform}" == 'pc' -a -f '/boot/memtest86+/memtest' ]; then
menuentry 'Run Memtest86+ (RAM test)' --class memtest86 --class memtest --class gnu --class tool {
set gfxpayload=800x600,1024x768
linux /boot/memtest86+/memtest
}
fi
if [ "${grub_platform}" == 'efi' ]; then
if [ "${grub_cpu}" == 'x86_64' -a -f '/shellx64.efi' ]; then
menuentry 'UEFI Shell' --class efi {
chainloader /shellx64.efi chainloader /shellx64.efi
} }
elif [ "${grub_cpu}" == "i386" ]; then elif [ "${grub_cpu}" == "i386" -a -f '/shellia32.efi' ]; then
menuentry "UEFI Shell" --class efi { menuentry 'UEFI Shell' --class efi {
insmod chain
chainloader /shellia32.efi chainloader /shellia32.efi
} }
fi fi
@ -76,12 +101,15 @@ if [ "${grub_platform}" == "efi" ]; then
} }
fi fi
menuentry "System restart" --class reboot --class restart {
echo "System rebooting..." menuentry 'System restart' --class reboot --class restart {
echo 'System rebooting...'
reboot reboot
} }
menuentry "System shutdown" --class shutdown --class poweroff { menuentry 'System shutdown' --class shutdown --class poweroff {
echo "System shutting down..." echo 'System shutting down...'
halt halt
} }
# GRUB init tune for accessibility
play 600 988 1 1319 4

80
archiso/grub/loopback.cfg

@ -0,0 +1,80 @@
# https://www.supergrubdisk.org/wiki/Loopback.cfg
# Search for the ISO volume
search --no-floppy --set=archiso_img_dev --file "${iso_path}"
probe --set archiso_img_dev_uuid --fs-uuid "${archiso_img_dev}"
# Get a human readable platform identifier
if [ "${grub_platform}" == 'efi' ]; then
archiso_platform='UEFI'
if [ "${grub_cpu}" == 'x86_64' ]; then
archiso_platform="x64 ${archiso_platform}"
elif [ "${grub_cpu}" == 'i386' ]; then
archiso_platform="IA32 ${archiso_platform}"
else
archiso_platform="${grub_cpu} ${archiso_platform}"
fi
elif [ "${grub_platform}" == 'pc' ]; then
archiso_platform='BIOS'
else
archiso_platform="${grub_cpu} ${grub_platform}"
fi
# Set default menu entry
default=archlinux
timeout=15
timeout_style=menu
# Menu entries
menuentry "Arch Linux install medium (%ARCH%, ${archiso_platform})" --class arch --class gnu-linux --class gnu --class os --id 'archlinux' {
set gfxpayload=keep
linux /%INSTALL_DIR%/boot/%ARCH%/vmlinuz-linux archisobasedir=%INSTALL_DIR% img_dev=UUID=${archiso_img_dev_uuid} img_loop="${iso_path}"
initrd /%INSTALL_DIR%/boot/intel-ucode.img /%INSTALL_DIR%/boot/amd-ucode.img /%INSTALL_DIR%/boot/%ARCH%/initramfs-linux.img
}
menuentry "Arch Linux install medium with speakup screen reader (%ARCH%, ${archiso_platform})" --hotkey s --class arch --class gnu-linux --class gnu --class os --id 'archlinux-accessibility' {
set gfxpayload=keep
linux /%INSTALL_DIR%/boot/%ARCH%/vmlinuz-linux archisobasedir=%INSTALL_DIR% img_dev=UUID=${archiso_img_dev_uuid} img_loop="${iso_path}" accessibility=on
initrd /%INSTALL_DIR%/boot/intel-ucode.img /%INSTALL_DIR%/boot/amd-ucode.img /%INSTALL_DIR%/boot/%ARCH%/initramfs-linux.img
}
if [ "${grub_platform}" == 'efi' -a "${grub_cpu}" == 'x86_64' -a -f '/boot/memtest86+/memtest.efi' ]; then
menuentry 'Run Memtest86+ (RAM test)' --class memtest86 --class memtest --class gnu --class tool {
set gfxpayload=800x600,1024x768
linux /boot/memtest86+/memtest.efi
}
fi
if [ "${grub_platform}" == 'pc' -a -f '/boot/memtest86+/memtest' ]; then
menuentry 'Run Memtest86+ (RAM test)' --class memtest86 --class memtest --class gnu --class tool {
set gfxpayload=800x600,1024x768
linux /boot/memtest86+/memtest
}
fi
if [ "${grub_platform}" == 'efi' ]; then
if [ "${grub_cpu}" == 'x86_64' -a -f '/shellx64.efi' ]; then
menuentry 'UEFI Shell' --class efi {
chainloader /shellx64.efi
}
elif [ "${grub_cpu}" == "i386" -a -f '/shellia32.efi' ]; then
menuentry 'UEFI Shell' --class efi {
chainloader /shellia32.efi
}
fi
menuentry 'UEFI Firmware Settings' --id 'uefi-firmware' {
fwsetup
}
fi
menuentry 'System shutdown' --class shutdown --class poweroff {
echo 'System shutting down...'
halt
}
menuentry 'System restart' --class reboot --class restart {
echo 'System rebooting...'
reboot
}

5
archiso/packages.x86_64

@ -4,7 +4,9 @@ arch-install-scripts
archinstall archinstall
b43-fwcutter b43-fwcutter
base base
bcachefs-tools
bind bind
bolt
brltty brltty
broadcom-wl broadcom-wl
btrfs-progs btrfs-progs
@ -78,6 +80,7 @@ nvme-cli
open-iscsi open-iscsi
open-vm-tools open-vm-tools
openconnect openconnect
openpgp-card-tools
openssh openssh
openvpn openvpn
partclone partclone
@ -96,6 +99,7 @@ rsync
rxvt-unicode-terminfo rxvt-unicode-terminfo
screen screen
sdparm sdparm
sequoia-sq
sg3_utils sg3_utils
smartmontools smartmontools
sof-firmware sof-firmware
@ -107,6 +111,7 @@ tcpdump
terminus-font terminus-font
testdisk testdisk
tmux tmux
tpm2-tools
tpm2-tss tpm2-tss
udftools udftools
usb_modeswitch usb_modeswitch

1
archiso/profiledef.sh

@ -19,6 +19,7 @@ file_permissions=(
["/etc/shadow"]="0:0:400" ["/etc/shadow"]="0:0:400"
["/root"]="0:0:750" ["/root"]="0:0:750"
["/root/.automated_script.sh"]="0:0:755" ["/root/.automated_script.sh"]="0:0:755"
["/root/.gnupg"]="0:0:700"
["/usr/local/bin/choose-mirror"]="0:0:755" ["/usr/local/bin/choose-mirror"]="0:0:755"
["/usr/local/bin/Installation_guide"]="0:0:755" ["/usr/local/bin/Installation_guide"]="0:0:755"
["/usr/local/bin/livecd-sound"]="0:0:755" ["/usr/local/bin/livecd-sound"]="0:0:755"

Loading…
Cancel
Save