File tree Expand file tree Collapse file tree
minimum/airootfs.any/root
livecd-sound/airootfs.any/usr/local/bin
user/airootfs.any/etc/systemd/system/getty@tty1.service.d Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -17,13 +17,11 @@ automated_script() {
1717 script=" $( script_cmdline) "
1818 if [[ -n " ${script} " && ! -x /tmp/startup_script ]]; then
1919 if [[ " ${script} " =~ ^(( http| https| ftp| tftp):// ) ]]; then
20- # there's no synchronization for network availability before executing this script
21- printf '%s: waiting for network-online.target\n' "$0 "
22- until systemctl --quiet is-active network-online.target; do
23- sleep 1
24- done
25- printf '%s: downloading %s\n' "$0 " "${script} "
26- curl "${script} " -- location -- retry- connrefused -- retry 10 -- fail - s - o / tmp/ startup_script
20+ # there's no synchronization for network availability before executing this script; to ensure the network
21+ # is online, we use a transient systemd service that depends on network-online.target to download the
22+ # script rather than manually polling the target
23+ systemd-run --pty --quiet -p Wants=network-online.target -p After=network-online.target \
24+ curl "${script} " -- location -- retry- connrefused -- retry 10 -- fail - s - o / tmp/ startup_script
2725 rt=$?
2826 else
2927 cp "${script} " / tmp/ startup_script
Original file line number Diff line number Diff line change @@ -17,13 +17,11 @@ automated_script() {
1717 script=" $( script_cmdline) "
1818 if [[ -n " ${script} " && ! -x /tmp/startup_script ]]; then
1919 if [[ " ${script} " =~ ^(( http| https| ftp| tftp):// ) ]]; then
20- # there's no synchronization for network availability before executing this script
21- printf '%s: waiting for network-online.target\n' "$0 "
22- until systemctl --quiet is-active network-online.target; do
23- sleep 1
24- done
25- printf '%s: downloading %s\n' "$0 " "${script} "
26- curl "${script} " -- location -- retry- connrefused -- retry 10 -- fail - s - o / tmp/ startup_script
20+ # there's no synchronization for network availability before executing this script; to ensure the network
21+ # is online, we use a transient systemd service that depends on network-online.target to download the
22+ # script rather than manually polling the target
23+ systemd-run --pty --quiet -p Wants=network-online.target -p After=network-online.target \
24+ curl "${script} " -- location -- retry- connrefused -- retry 10 -- fail - s - o / tmp/ startup_script
2725 rt=$?
2826 else
2927 cp "${script} " / tmp/ startup_script
Original file line number Diff line number Diff line change @@ -8,7 +8,7 @@ usage() {
88 Usage: livecdsound [OPTION]
99 OPTIONS
1010 -u, --unmute unmute all sound cards
11- -p, --pick select a card for speetch output
11+ -p, --pick select a card for speech output
1212 -h, --help Show this usage message
1313
1414_EOF_
@@ -183,8 +183,8 @@ play_on_card() {
183183# using auditory feedback.
184184pick_a_card () {
185185 set -f
186- usable_cards= " $ ( list_non_pcsp_cards) "
187- num_usable_cards=" $( wc -w <<< " $ usable_cards" ) "
186+ mapfile -t usable_cards < < ( list_non_pcsp_cards)
187+ num_usable_cards=" ${ # usable_cards[@]} "
188188
189189 if (( num_usable_cards == 1 )) ; then
190190 systemd-cat -t " livecdsound" printf " Only one sound card is detected\n"
Original file line number Diff line number Diff line change 11[Service]
22ExecStart=
3- ExecStart=-/sbin/ agetty -o '-p -f -- \\u' -- noclear --autologin %ALTERISO_USERNAME% - $TERM
3+ ExecStart=-/usr/bin/ agetty --noreset -- noclear --autologin %ALTERISO_USERNAME% - ${ TERM}
You can’t perform that action at this time.
0 commit comments