X-Git-Url: https://iankelling.org/git/?p=automated-distro-installer;a=blobdiff_plain;f=fai%2Fconfig%2Fscripts%2FIANK%2F11-iank;fp=fai%2Fconfig%2Fscripts%2FIANK%2F11-iank;h=6c9c9bf1f29ce87929ba1d3283253908a0b02c9f;hp=98798631a9665ccd344dd3589d2d2e0791cb16ba;hb=a15c2ba88789fd9a37bd5a860fda1b3877999421;hpb=8bb06901ce000f76dafc73288e1fe47c3032e4af diff --git a/fai/config/scripts/IANK/11-iank b/fai/config/scripts/IANK/11-iank index 9879863..6c9c9bf 100755 --- a/fai/config/scripts/IANK/11-iank +++ b/fai/config/scripts/IANK/11-iank @@ -225,38 +225,12 @@ EOF fi # for new btrfs features, get latest stable kernel and btrfs progs, -# update ver= as needed. +# update ver= when we are ready to jump to a new stable kernel. +# note: this is duplicated in install-stable-kernel-debs. +ver='6\.6' case $HOSTNAME in sy) - mkdir -p $FAI_ROOT/tmp/kernel-debs - files=($FAI_ROOT/tmp/kernel-debs/*) - if (( ${#files[@]} >= 1 )); then - rm -rf "${files[@]}" - fi - cd $FAI_ROOT/tmp/kernel-debs - ver='6\.6' - va=$(curl -s https://kernel.ubuntu.com/mainline/ | \ - sed -rn 's,.*alt="\[DIR\]".*href="([^/]+).*,\1,p' | \ - grep -v -- -rc | sed 's/^v//' | grep "^$ver" | sort -V | tail -n1) - - # note the wiki page about these says to install linux-headers.*generic.*amd64, but - # as of 2024, they have a requirement of a very new glibc, and people report - # that installing it is not needed. - pkgs=$(curl -s https://kernel.ubuntu.com/mainline/v$va/amd64/CHECKSUMS | awk '$2 ~ /^linux-/ { print $2 }' | sort -u | grep -iv 'linux-headers.*generic.*amd64' ) - - urls=() - for p in $pkgs; do - if ! dpkg -s -- "${p%%_*}" 2>&1 | grep -Fx "Status: install ok installed" &>/dev/null; then - urls+=(https://kernel.ubuntu.com/mainline/v$va/amd64/$p) - fi - done - if (( ${#urls[@]} >= 1 )); then - wget "${urls[@]}" - $chroot bash </dev/null | awk '{print $2}') ||: if [[ $ver != "$cur_ver" ]]; then - if [[ $HOST2 == $HOSTNAME && $ver != "$($bprogs_dir/btrfs --version 2>/dev/null | awk '{print $2}')" ]]; then + if [[ $HOST2 == "$HOSTNAME" && $ver != "$($bprogs_dir/btrfs --version 2>/dev/null | awk '{print $2}')" ]]; then rm -rf $bprogs_dir cd /tmp wget $url