summaryrefslogtreecommitdiffstats
path: root/debian/icinga2-ido-pgsql.config
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-28 12:34:55 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-28 12:34:55 +0000
commit58306b0f7e29c41c00ab7bbd99d7686299f1de77 (patch)
treeb737b9d2d0a29c485e78c545d5434f13d923c91e /debian/icinga2-ido-pgsql.config
parentAdding upstream version 2.13.6. (diff)
downloadicinga2-debian/2.13.6-2.tar.xz
icinga2-debian/2.13.6-2.zip
Adding debian version 2.13.6-2.debian/2.13.6-2
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