postinst is in libhesiod0 3.2.1-3build1.
This file is a maintainer script. It is executed when installing (*inst) or removing (*rm) the package.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 | #!/bin/sh -e
# Source debconf library.
. /usr/share/debconf/confmodule
# Load debconf values
db_version 2.0
db_get hesiod/rhs
rhs="$RET"
db_get hesiod/lhs
lhs="$RET"
db_get hesiod/classes
classes="$RET"
hesconf=/etc/hesiod.conf
createhesconf() {
cat <<EOF > "$hesconf"
# This file determines the behavior of the Hesiod library.
# This line should pretty much always be the same, unless you have a
# funny environment.
lhs=$lhs
# This determines the Hesiod domain. You must specify an rhs line.
rhs=$rhs
# This line specifies the class search order. You can reverse the
# order or leave out IN or HS if you want. Don't add spaces after the
# beginning of the value.
classes=$classes
EOF
}
edithesconf() {
sed -e "s/^lhs=.*/lhs=$lhs/" \
-e "s/^rhs=.*/rhs=$rhs/" \
-e "s/^classes=.*/classes=$classes/" \
-i "$hesconf"
}
case "$1" in
configure)
if [ ! -f "$hesconf" ]; then
createhesconf
else
edithesconf
fi
;;
abort-upgrade|abort-remove|abort-deconfigure)
;;
*)
echo "postinst called with unknown argument \`$1'" >&2
exit 1
;;
esac
exit 0
|