summaryrefslogtreecommitdiff
path: root/packages/debian/cloud-init.postinst
blob: cdd0466d6da17458b80141da17a6631fd7e95778 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#!/bin/sh
cleanup_lp1552999() {
    local oldver="$1" last_bad_ver="0.7.7~bzr1178"
    dpkg --compare-versions "$oldver" le "$last_bad_ver" || return 0
    local edir="/etc/systemd/system/multi-user.target.wants"
    rm -f "$edir/cloud-config.service" "$edir/cloud-final.service" \
        "$edir/cloud-init-local.service" "$edir/cloud-init.service"
}


#DEBHELPER#

if [ "$1" = "configure" ]; then
   oldver="$2"
   cleanup_lp1552999 "$oldver"
fi