This file is indexed.

postinst is in cacti-spine 0.8.7i-1ubuntu1.

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
#!/bin/sh

set -e

generate_config() {
	confdbc=/usr/share/doc/cacti-spine/spine.conf.dbconfig
	confsrc=/usr/share/doc/cacti-spine/spine.conf.sample
	if [ -f "/etc/dbconfig-common/cacti.conf" ]; then
		dbconfig-generate-include -U -f template -o "template_infile=$confdbc" /etc/dbconfig-common/cacti.conf /etc/cacti/spine.conf
	else
		ucf $confsrc /etc/cacti/spine.conf
	fi
  ucfr cacti-spine /etc/cacti/spine.conf
	chown root:www-data /etc/cacti/spine.conf
	chmod 640 /etc/cacti/spine.conf
}

case "$1" in
"configure"|"reconfigure"|"upgrade")
	. /usr/share/debconf/confmodule
	db_version 2.0

	generate_config
;;
esac