mirror of
https://github.com/systemd/systemd-stable.git
synced 2024-12-23 17:34:00 +03:00
Merge pull request #16777 from DaanDeMeyer/kernel-install-followup
kernel-install: "Linux" => "Default" and reuse $BOOT/Default if it already exists
This commit is contained in:
commit
c3bbc90b4a
@ -85,10 +85,13 @@ fi
|
||||
KERNEL_VERSION="$1"
|
||||
KERNEL_IMAGE="$2"
|
||||
|
||||
if [[ -f /etc/machine-id ]]; then
|
||||
# Reuse directory created without a machine ID present if it exists.
|
||||
if [[ -d /efi/Default ]] || [[ -d /boot/Default ]] || [[ -d /boot/efi/Default ]]; then
|
||||
MACHINE_ID="Default"
|
||||
elif [[ -f /etc/machine-id ]]; then
|
||||
read MACHINE_ID < /etc/machine-id
|
||||
else
|
||||
MACHINE_ID="Linux"
|
||||
MACHINE_ID="Default"
|
||||
fi
|
||||
|
||||
if [[ ! $COMMAND ]] || [[ ! $KERNEL_VERSION ]]; then
|
||||
|
Loading…
Reference in New Issue
Block a user