summaryrefslogtreecommitdiffstats
path: root/debian/open-infrastructure-container-tools.config
blob: 73d2157af1658c4a9928c8679198f311cd621da9 (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
33
34
35
36
37
38
39
40
41
42
43
44
45
#!/bin/sh

set -e

. /usr/share/debconf/confmodule

db_settitle open-infrastructure-container-tools/title
db_input low open-infrastructure-container-tools/machines || true
db_go

db_settitle open-infrastructure-container-tools/title
db_input low open-infrastructure-container-tools/config || true
db_go

db_settitle open-infrastructure-container-tools/title
db_input low open-infrastructure-container-tools/debconf || true
db_go

db_settitle open-infrastructure-container-tools/title
db_input low open-infrastructure-container-tools/cache || true
db_go

SCRIPT_CHOICES="$(cd /usr/share/container-tools/scripts && find -maxdepth 1 -not -type d -and -not -name 'debconf' -and -not -name '*.d' -printf '%P\n' | sort)"
db_subst open-infrastructure-container-tools/script SCRIPT_CHOICES "$(echo ${SCRIPT_CHOICES} | sed -e 's| |, |g')"

DISTRIBUTOR="$(lsb_release -is 2>/dev/null)"
DISTRIBUTOR="${DISTRIBUTOR:-Debian}"

case "${DISTRIBUTOR}" in
	Progress*)
		SCRIPT_DEFAULT="progress-linux"
		;;

	*)
		SCRIPT_DEFAULT="debian"
		;;
esac

db_subst open-infrastructure-container-tools/script SCRIPT_DEFAULT "${SCRIPT_DEFAULT}"

db_settitle open-infrastructure-container-tools/title
db_input low open-infrastructure-container-tools/script || true
db_go

db_stop