summaryrefslogtreecommitdiffstats
path: root/debian/icinga2-ido-pgsql.config
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-13 11:32:39 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-13 11:32:39 +0000
commitb86b946791f8dcc23ed6c47d513e34ebb22c1610 (patch)
tree9893d33a249fbf175f69e9f18a7fa0b84718ec24 /debian/icinga2-ido-pgsql.config
parentAdding upstream version 2.14.2. (diff)
downloadicinga2-b86b946791f8dcc23ed6c47d513e34ebb22c1610.tar.xz
icinga2-b86b946791f8dcc23ed6c47d513e34ebb22c1610.zip
Adding debian version 2.14.2-1.debian/2.14.2-1debian
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'debian/icinga2-ido-pgsql.config')
-rw-r--r--debian/icinga2-ido-pgsql.config21
1 files changed, 21 insertions, 0 deletions
diff --git a/debian/icinga2-ido-pgsql.config b/debian/icinga2-ido-pgsql.config
new file mode 100644
index 0000000..8a59cf7
--- /dev/null
+++ b/debian/icinga2-ido-pgsql.config
@@ -0,0 +1,21 @@
+#!/bin/sh
+set -e
+
+. /usr/share/debconf/confmodule
+
+if [ -f /usr/share/dbconfig-common/dpkg/config.pgsql ]; then
+ . /usr/share/dbconfig-common/dpkg/config.pgsql
+ dbc_dbname=icinga2
+ dbc_dbuser=icinga2
+ dbc_authmethod_user="password"
+ dbc_go icinga2-ido-pgsql $@
+fi
+
+# check if the feature is enabled
+if test -L /etc/icinga2/features-enabled/ido-pgsql.conf; then
+ db_set icinga2-ido-pgsql/enable "true"
+else
+ db_set icinga2-ido-pgsql/enable "false"
+fi
+db_input high icinga2-ido-pgsql/enable || true
+db_go || true