~linaro-validation/lava-dashboard/packaging

« back to all changes in this revision

Viewing changes to debian/postrm

  • Committer: Zygmunt Krynicki
  • Date: 2011-07-13 18:31:05 UTC
  • Revision ID: zygmunt.krynicki@linaro.org-20110713183105-sumssy1uppvysob2
Tags: 0.6~b3-0ubuntu0~lava1
* New upstream beta release

Bug fixes:

* Fix breadcrumb in attachment detail view
* Fix link to images in test result list
* Display dates as numbers so that they sort properly
* Improve wording in table header

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#!/bin/sh
 
2
set -e
 
3
 
 
4
# dh_installdeb will replace this with shell code automatically
 
5
# generated by other debhelper scripts.
 
6
#DEBHELPER#
 
7
 
 
8
# Source debconf library
 
9
if [ -f /usr/share/debconf/confmodule ]; then
 
10
    . /usr/share/debconf/confmodule
 
11
fi
 
12
 
 
13
# Check that lava-server is installed
 
14
if [ ! -f /var/lib/dpkg/info/lava-server.config ]; then
 
15
    exit
 
16
fi
 
17
 
 
18
# Check that django-debian in installed
 
19
if [ ! -f /usr/share/django-debian/dpkg/postinst ]; then
 
20
    exit
 
21
fi
 
22
 
 
23
# Read django-debian configuration variables from the lava-server.config file
 
24
# This is highly hacky but we don't have a better interface yet. Ultimately
 
25
# we'd like to query the actual settings from some django-debian helper.
 
26
# Currently there is no customizability so we can assume that the initial
 
27
# settings fused in the config script are correct.
 
28
META_DATA=$(mktemp)
 
29
grep -e 'django_debian_.*=".*"' /var/lib/dpkg/info/lava-server.config > $META_DATA
 
30
. $META_DATA
 
31
rm -f $META_DATA
 
32
 
 
33
# Source the django-debian postinst script and pretend to be lava server.
 
34
 
 
35
# NOTE: This is not an accident. Removing or installing an extension have
 
36
# identical consequences to the master application. We need to rebuild static
 
37
# files and reconfigure the web server. Here we do a bit too much (database
 
38
# migration is not needed as the database is simply not touched by this step)
 
39
# but it should be harmless
 
40
. /usr/share/django-debian/dpkg/postinst
 
41
_django_debian_config lava-server "$@"
 
42
_django_debian_debug "removing lava-server extension: lava-dashboard"
 
43
_django_debian_configure_web_app
 
44
_django_debian_configure_web_server_postinst