postinst is in ftp-cloudfs 0.25.2-1.
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 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42  | #!/bin/sh
set -e
if [ "$1" = "configure" ] ; then
	if ! getent group ftpcloudfs > /dev/null 2>&1 ; then
		addgroup --system ftpcloudfs >/dev/null
	fi
	if ! getent passwd ftpcloudfs > /dev/null 2>&1 ; then
		adduser --system --home /var/log/ftp-cloudfs --ingroup ftpcloudfs --no-create-home --shell /bin/false ftpcloudfs > /dev/null 2>&1
	fi
	# log directory
	mkdir -m 0700 -p /var/log/ftp-cloudfs
	touch /var/log/ftp-cloudfs/ftp-cloudfs.log
	chmod 0640 /var/log/ftp-cloudfs/ftp-cloudfs.log
	chown -R ftpcloudfs:ftpcloudfs /var/log/ftp-cloudfs
	# pid file directory
	mkdir -m 0700 -p /var/run/ftp-cloudfs
	chown -R ftpcloudfs:ftpcloudfs /var/run/ftp-cloudfs
	if [ ! -e /etc/ftpcloudfs.conf ] ; then
		install -D -m 0640 -g ftpcloudfs -o ftpcloudfs /usr/share/ftpcloudfs/ftpcloudfs.conf /etc/ftpcloudfs.conf
		MY_GID=`id -g ftpcloudfs`
		MY_UID=`id -u ftpcloudfs`
		sed -i -e "s#^[ \t]*uid[ \t]*=.*#uid = ${MY_UID}#" /etc/ftpcloudfs.conf
		sed -i -e "s#^[ \t]*gid[ \t]*=.*#gid = ${MY_GID}#" /etc/ftpcloudfs.conf
	fi
fi
# Automatically added by dh_installinit
if [ -x "/etc/init.d/ftp-cloudfs" ] || [ -e "/etc/init/ftp-cloudfs.conf" ]; then
	if [ ! -e "/etc/init/ftp-cloudfs.conf" ]; then
		update-rc.d ftp-cloudfs defaults >/dev/null
	fi
	invoke-rc.d ftp-cloudfs start || true
fi
# End automatically added section
exit 0
 |