Skip to content

Commit

Permalink
Automatically upgrade initoverlayfs on upgrade
Browse files Browse the repository at this point in the history
With this script we automatically rebuild initoverlayfs on kernel
upgrade.

Signed-off-by: Eric Curtin <[email protected]>
  • Loading branch information
ericcurtin committed Feb 11, 2024
1 parent b373b65 commit 2b942a8
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 5 deletions.
2 changes: 1 addition & 1 deletion build-scripts/version.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# SPDX-License-Identifier: LGPL-2.1-or-later

# Current version of initoverlayfs
VERSION=0.991
VERSION=0.992
# Specify if build is a official release or a snapshot build
IS_RELEASE=false
# Used for official releases. Increment if necessary
Expand Down
8 changes: 4 additions & 4 deletions initoverlayfs.spec.in
Original file line number Diff line number Diff line change
Expand Up @@ -44,10 +44,10 @@ install -D -m644 lib/systemd/system/pre-initoverlayfs-switch-root.service ${RPM_
%{_prefix}/lib/systemd/system/pre-initoverlayfs-switch-root.service

%changelog
* Wed Jan 17 2024 Stephen Smoogen <ssmoogen@redhat.com> - 0.991-1
- Update to 0.991 release.
- fork storage-init as a systemd unit (ecurtin)
- shell-less initrd work (ecurtin)
* Wed Feb 11 2024 Eric Curtin <ecurtin@redhat.com> - 0.992-1
- Update to 0.992 release.
- Automatically rebuild kernel on upgrade (ecurtin)
- Build initrd in no-hostonly mode for generic initrd (ecurtin)

* Thu Dec 14 2023 Stephen Smoogen <[email protected]> - 0.99-1
- Update to 0.99 release.
Expand Down
16 changes: 16 additions & 0 deletions lib/kernel/install.d/94-initoverlayfs.install
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
#!/usr/bin/bash

COMMAND="$1"
KERNEL_VERSION="$2"

case "$COMMAND" in
add)
initoverlayfs-install --kver "$KERNEL_VERSION"
;;
remove)
rm -f /boot/initoverlayfs-$KERNEL_VERSION
;;
*)
exit 0
esac

0 comments on commit 2b942a8

Please sign in to comment.