summarylogtreecommitdiffstats
path: root/airvpn-suite.install
blob: fe6a7d9fdf9bd4e07d06651dc6852e7c70db7dca (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
post_install() {
	getent passwd airvpn >/dev/null
    if [ $? -eq '2' ]; then
        useradd -Um airvpn
    fi
    chown -R airvpn:airvpn /etc/airvpn
    systemctl daemon-reload
}

pre_upgrade() {
    systemctl stop bluetit.service
}

pre_remove() {
    systemctl stop bluetit.service
    systemctl disable bluetit.service
}

post_remove() {
    userdel -r airvpn 2>/dev/null
    getent group airvpn >/dev/null && gpasswd airvpn -M "" && groupdel airvpn
    systemctl daemon-reload
}