mirror of
https://github.com/kairos-io/packages.git
synced 2025-09-17 15:40:44 +00:00
uki fixes for cc files (#608)
This commit is contained in:
@@ -1,4 +1,4 @@
|
|||||||
packages:
|
packages:
|
||||||
- name: "kairos-overlay-files"
|
- name: "kairos-overlay-files"
|
||||||
category: "static"
|
category: "static"
|
||||||
version: "1.1.19"
|
version: "1.1.20"
|
||||||
|
@@ -22,7 +22,7 @@ stages:
|
|||||||
# the boot stage.
|
# the boot stage.
|
||||||
- name: "Remove GRUB sentinels"
|
- name: "Remove GRUB sentinels"
|
||||||
if: |
|
if: |
|
||||||
cat /proc/cmdline | grep -q "active.img"
|
cat /proc/cmdline | grep -q "active.img" && grep -vq "rd.immucore.uki" /proc/cmdline
|
||||||
commands:
|
commands:
|
||||||
- |
|
- |
|
||||||
mount -o rw,remount /run/initramfs/cos-state
|
mount -o rw,remount /run/initramfs/cos-state
|
||||||
@@ -31,7 +31,7 @@ stages:
|
|||||||
mount -o ro,remount /run/initramfs/cos-state
|
mount -o ro,remount /run/initramfs/cos-state
|
||||||
- name: "Create upgrade failure sentinel if necessary"
|
- name: "Create upgrade failure sentinel if necessary"
|
||||||
if: |
|
if: |
|
||||||
cat /proc/cmdline | grep -q "upgrade_failure"
|
cat /proc/cmdline | grep -q "upgrade_failure" && grep -vq "rd.immucore.uki" /proc/cmdline
|
||||||
files:
|
files:
|
||||||
- path: /run/cos/upgrade_failure
|
- path: /run/cos/upgrade_failure
|
||||||
content: "1"
|
content: "1"
|
||||||
@@ -44,6 +44,7 @@ stages:
|
|||||||
|
|
||||||
- &statemount
|
- &statemount
|
||||||
name: "Mount state"
|
name: "Mount state"
|
||||||
|
if: grep -vq "rd.immucore.uki" /proc/cmdline
|
||||||
commands:
|
commands:
|
||||||
- |
|
- |
|
||||||
STATEDIR=/tmp/mnt/STATE
|
STATEDIR=/tmp/mnt/STATE
|
||||||
@@ -56,7 +57,7 @@ stages:
|
|||||||
- &customhook
|
- &customhook
|
||||||
name: "Hook boot assessment grub configuration"
|
name: "Hook boot assessment grub configuration"
|
||||||
if: |
|
if: |
|
||||||
! grep -q "grub_boot_assessment" /tmp/mnt/STATE/grubcustom
|
! grep -q "grub_boot_assessment" /tmp/mnt/STATE/grubcustom && grep -vq "rd.immucore.uki" /proc/cmdline
|
||||||
commands:
|
commands:
|
||||||
- |
|
- |
|
||||||
cat << 'EOF' >> /tmp/mnt/STATE/grubcustom
|
cat << 'EOF' >> /tmp/mnt/STATE/grubcustom
|
||||||
@@ -75,6 +76,7 @@ stages:
|
|||||||
# This configuration is separated so it can be tracked separately from the install hook
|
# This configuration is separated so it can be tracked separately from the install hook
|
||||||
- &bootgrub
|
- &bootgrub
|
||||||
name: "Add boot assessment grub configuration"
|
name: "Add boot assessment grub configuration"
|
||||||
|
if: grep -vq "rd.immucore.uki" /proc/cmdline
|
||||||
files:
|
files:
|
||||||
- path: "/tmp/mnt/STATE/grub_boot_assessment"
|
- path: "/tmp/mnt/STATE/grub_boot_assessment"
|
||||||
owner: 0
|
owner: 0
|
||||||
@@ -100,11 +102,12 @@ stages:
|
|||||||
fi
|
fi
|
||||||
- &grubinstall
|
- &grubinstall
|
||||||
name: "Grub branding"
|
name: "Grub branding"
|
||||||
if: '[ -e "/etc/kairos/branding/grubmenu.cfg" ]'
|
if: '[ -e "/etc/kairos/branding/grubmenu.cfg" ] && grep -vq "rd.immucore.uki" /proc/cmdline'
|
||||||
commands:
|
commands:
|
||||||
- cp -rfv /etc/kairos/branding/grubmenu.cfg /tmp/mnt/STATE/grubmenu
|
- cp -rfv /etc/kairos/branding/grubmenu.cfg /tmp/mnt/STATE/grubmenu
|
||||||
- &stateumount
|
- &stateumount
|
||||||
name: "umount state"
|
name: "umount state"
|
||||||
|
if: grep -vq "rd.immucore.uki" /proc/cmdline
|
||||||
commands:
|
commands:
|
||||||
- umount /tmp/mnt/STATE
|
- umount /tmp/mnt/STATE
|
||||||
|
|
||||||
@@ -113,6 +116,7 @@ stages:
|
|||||||
after-upgrade:
|
after-upgrade:
|
||||||
- <<: *statemount
|
- <<: *statemount
|
||||||
- name: "Set upgrade sentinel"
|
- name: "Set upgrade sentinel"
|
||||||
|
if: grep -vq "rd.immucore.uki" /proc/cmdline
|
||||||
commands:
|
commands:
|
||||||
- |
|
- |
|
||||||
grub2-editenv /tmp/mnt/STATE/boot_assessment set enable_boot_assessment=yes
|
grub2-editenv /tmp/mnt/STATE/boot_assessment set enable_boot_assessment=yes
|
||||||
|
@@ -17,7 +17,7 @@ stages:
|
|||||||
groups:
|
groups:
|
||||||
- "admin"
|
- "admin"
|
||||||
- name: "Set user password if running in live or uki"
|
- name: "Set user password if running in live or uki"
|
||||||
if: "[ -e /run/cos/live_mode ] || [ -e /run/cos/uki_install_mode ] || [ -e /run/cos/uki_boot_mode ]"
|
if: "[ -e /run/cos/live_mode ] || [ -e /run/cos/uki_install_mode ]"
|
||||||
users:
|
users:
|
||||||
kairos:
|
kairos:
|
||||||
passwd: "kairos"
|
passwd: "kairos"
|
||||||
|
@@ -3,7 +3,7 @@ stages:
|
|||||||
initramfs:
|
initramfs:
|
||||||
- if: |
|
- if: |
|
||||||
grep -qv "interactive-install" /proc/cmdline && \
|
grep -qv "interactive-install" /proc/cmdline && \
|
||||||
[ -f /run/cos/live_mode ] && \
|
[ -f /run/cos/live_mode ] || [ -f /run/cos/uki_install_mode ] && \
|
||||||
( [ -e "/sbin/systemctl" ] || [ -e "/usr/bin/systemctl" ] || [ -e "/usr/sbin/systemctl" ] || [ -e "/usr/bin/systemctl" ] )
|
( [ -e "/sbin/systemctl" ] || [ -e "/usr/bin/systemctl" ] || [ -e "/usr/sbin/systemctl" ] || [ -e "/usr/bin/systemctl" ] )
|
||||||
files:
|
files:
|
||||||
- path: /etc/systemd/system/serial-getty@ttyS0.service.d/override.conf
|
- path: /etc/systemd/system/serial-getty@ttyS0.service.d/override.conf
|
||||||
|
Reference in New Issue
Block a user