1
0
Fork 0

Rewriting postinst with the standard maintainer script.

Signed-off-by: Daniel Baumann <daniel@debian.org>
This commit is contained in:
Daniel Baumann 2025-02-16 11:31:14 +01:00
parent cfe5968bf1
commit 02ba105e52
Signed by: daniel
GPG key ID: FBB4F0E80A80222F

View file

@ -2,14 +2,29 @@
set -e
if [ "$1" = "configure" ]; then
if [ ! -s /etc/nvme/hostnqn ]; then
case "${1}" in
configure)
if [ ! -s /etc/nvme/hostnqn ]
then
nvme gen-hostnqn > /etc/nvme/hostnqn
fi
if [ ! -s /etc/nvme/hostid ]; then
if [ ! -s /etc/nvme/hostid ]
then
uuidgen > /etc/nvme/hostid
fi
fi
;;
abort-upgrade|abort-remove|abort-deconfigure)
;;
*)
echo "postinst called with unknown argument \`${1}'" >&2
exit 1
;;
esac
#DEBHELPER#
exit 0