This file is indexed.

postrm is in openstack-dashboard 1:2014.1-0ubuntu1.

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
# vim: set ts=2 et:

set -e

CONF="openstack-dashboard.conf"

# /etc/apache2/conf.d/dashboard.conf -> /etc/apache2/conf-available/openstack-dashboard.conf
dpkg-maintscript-helper mv_conffile \
  /etc/apache2/conf.d/dashboard.conf /etc/apache2/conf-available/$CONF \
  2012.1~rc1-0ubuntu1 -- "$@"

# Transition config to apache 2.4 compatable location.
dpkg-maintscript-helper mv_conffile \
  /etc/apache2/conf.d/openstack-dashboard.conf \
  /etc/apache2/conf-available/openstack-dashboard.conf \
  1:2013.2~b2-0ubuntu3 -- "$@"

if [ "$1" = "remove" ] || [ "$1" = "purge" ] ; then
  A22_STATE=$(dpkg-query -f '${Status}' -W 'apache2.2-common' 2>/dev/null | awk '{print $3}' || true)

  if [ -e /usr/share/apache2/apache2-maintscript-helper ] ; then
    # apache 2.4
    . /usr/share/apache2/apache2-maintscript-helper
    apache2_invoke disconf $CONF || exit $?
  elif [ "$A22_STATE" = "installed" ] || [ "$A22_STATE" = "unpacked" ] ; then
    # apache 2.2
    [ -d /etc/apache2/conf.d/ ] && [ -L /etc/apache2/conf.d/$CONF ] &&
      rm /etc/apache2/conf.d/$CONF
    [ -x /etc/init.d/apache2 ] && invoke-rc.d --quiet apache2 reload
  fi

fi

if [ "$1" = "purge" ] ; then
		if (which deluser && getent passwd horizon) > /dev/null 2>&1; then
			deluser --system --quiet --backup-to /var/lib horizon
    fi
		if (which delgroup && getent group horizon) > /dev/null 2>&1; then
			delgroup --system --quiet horizon
		fi
fi