summaryrefslogtreecommitdiff
path: root/bin/live-preseed
blob: add29bd903d99bf9c06bcf9bb3026874496b297d (plain)
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
#!/bin/sh

set -e

PATH=/usr/sbin:/usr/bin:/sbin:/bin

# Only do this once
if [ -z "${DEBCONF_REDIR}" ]
then
	exec <&4
	export DEBIAN_HAS_FRONTEND=1
	export DEBCONF_REDIR=1
fi

root="${1}"
. "$root/usr/share/debconf/confmodule"

question="${2}"
value="${3}"
seen="${4}"

[ "${seen}" ] || seen=true

if ! db_set "${question}" "${value}"
then
	db_register debian-installer/dummy "${question}"
	db_set "${question}" "${value}"
fi

db_fset "${question}" seen "${seen}"

exit 0