/mandos/trunk

To get this branch, use:
bzr branch http://bzr.recompile.se/loggerhead/mandos/trunk

« back to all changes in this revision

Viewing changes to debian/mandos-client.postinst

  • Committer: Björn Påhlsson
  • Date: 2011-10-02 19:33:45 UTC
  • mfrom: (24.1.186 mandos)
  • Revision ID: belorn@fukt.bsnet.se-20111002193345-83fdvai1j7phep7j
The domain name has changed, so the D-Bus bus and interface names must
change.  This commit adds support for both the old and new names.

The new domain name is "recompile.se", so the new D-Bus bus name will
be "se.recompile.Mandos".

Show diffs side-by-side

added added

removed removed

Lines of Context:
33
33
# Add user and group
34
34
add_mandos_user(){
35
35
    # Rename old "mandos" user and group
36
 
    case "`getent passwd mandos`" in
37
 
        *:Mandos\ password\ system,,,:/nonexistent:/bin/false)
38
 
            usermod --login _mandos mandos
39
 
            groupmod --new-name _mandos mandos
40
 
            return
41
 
            ;;
42
 
    esac
 
36
    if dpkg --compare-versions "$2" lt "1.0.3-1"; then
 
37
        case "`getent passwd mandos`" in
 
38
            *:Mandos\ password\ system,,,:/nonexistent:/bin/false)
 
39
                usermod --login _mandos mandos
 
40
                groupmod --new-name _mandos mandos
 
41
                return
 
42
                ;;
 
43
        esac
 
44
    fi
43
45
    # Create new user and group
44
46
    if ! getent passwd _mandos >/dev/null; then
45
47
        adduser --system --force-badname --quiet --home /nonexistent \