Skip to content

Commit 22dcb82

Browse files
authored
Merge pull request #8 from soaringDistributions/codex/modify-ops.sh-to-handle-lts-kernel-copy-failures
Final Codex try before I refactor, handle optional LTS copies gracefully in live build
2 parents 7e9e84a + 71f2908 commit 22dcb82

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

ops.sh

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -379,10 +379,10 @@ _live_sequence_in() {
379379
if cp "${_kernels[1]}" "$scriptLocal/livefs/image/vmlinuz-lts"; then
380380
_have_lts_kernel=true
381381
else
382-
_messagePlain_bad 'fail: copy secondary kernel into ISO tree'
383-
_messageFAIL
384-
_stop 1
385-
return 1
382+
_messagePlain_warn 'live: failed to copy secondary kernel; removing vmlinuz-lts'
383+
rm -f "$scriptLocal/livefs/image/vmlinuz-lts"
384+
_have_lts_kernel=false
385+
ub_ops_live_has_lts_kernel=false
386386
fi
387387
else
388388
_messageNormal 'live: secondary kernel missing; skipping vmlinuz-lts'
@@ -406,10 +406,10 @@ _live_sequence_in() {
406406
if cp "${_initrds[1]}" "$scriptLocal/livefs/image/initrd-lts"; then
407407
_have_lts_initrd=true
408408
else
409-
_messagePlain_bad 'fail: copy secondary initrd into ISO tree'
410-
_messageFAIL
411-
_stop 1
412-
return 1
409+
_messagePlain_warn 'live: failed to copy secondary initrd; removing initrd-lts'
410+
rm -f "$scriptLocal/livefs/image/initrd-lts"
411+
_have_lts_initrd=false
412+
ub_ops_live_has_lts_kernel=false
413413
fi
414414
else
415415
_messageNormal 'live: secondary initrd missing; skipping initrd-lts'

0 commit comments

Comments
 (0)