Move systemd stuff out of pre-deinstall
This commit is contained in:
@@ -30,6 +30,7 @@ install="
|
|||||||
$pkgname.post-deinstall
|
$pkgname.post-deinstall
|
||||||
$pkgname-systemd.post-install
|
$pkgname-systemd.post-install
|
||||||
$pkgname-systemd.post-upgrade
|
$pkgname-systemd.post-upgrade
|
||||||
|
$pkgname-systemd.pre-deinstall
|
||||||
"
|
"
|
||||||
subpackages="
|
subpackages="
|
||||||
$pkgname-systemd
|
$pkgname-systemd
|
||||||
|
|||||||
@@ -0,0 +1,8 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
set -eu
|
||||||
|
|
||||||
|
# Stop and disable all mullvad services
|
||||||
|
systemctl stop mullvad-daemon.service || true
|
||||||
|
systemctl disable mullvad-daemon.service || true
|
||||||
|
systemctl stop mullvad-early-boot-blocking.service || true
|
||||||
|
systemctl disable mullvad-early-boot-blocking.service || true
|
||||||
@@ -1,7 +1,7 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
set -eu
|
set -eu
|
||||||
|
|
||||||
# Overwrite the cached relay list with the one embedded in the package.
|
# Copy vendored relay list into place
|
||||||
mkdir -p /var/cache/mullvad-vpn \
|
mkdir -p /var/cache/mullvad-vpn \
|
||||||
&& cp /usr/share/mullvad-vpn/relays.json /var/cache/mullvad-vpn/relays.json \
|
&& cp /usr/share/mullvad-vpn/relays.json /var/cache/mullvad-vpn/relays.json \
|
||||||
|| echo "failed to install /var/cache/mullvad-vpn/relays.json"
|
|| echo "failed to install /var/cache/mullvad-vpn/relays.json"
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
set -eu
|
set -eu
|
||||||
|
|
||||||
# Overwrite the cached relay list with the one embedded in the package.
|
# Overwrite the cached relay list with the vendored one.
|
||||||
mkdir /var/cache/mullvad-vpn
|
mkdir -p /var/cache/mullvad-vpn \
|
||||||
cp /usr/share/mullvad-vpn/relays.json /var/cache/mullvad-vpn/relays.json
|
&& cp /usr/share/mullvad-vpn/relays.json /var/cache/mullvad-vpn/relays.json \
|
||||||
|
|| echo "failed to install /var/cache/mullvad-vpn/relays.json"
|
||||||
|
|||||||
@@ -1,11 +1,5 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
set -eu
|
set -eu
|
||||||
|
|
||||||
# the user might've disabled or stopped the service themselves already
|
|
||||||
systemctl stop mullvad-daemon.service || true
|
|
||||||
systemctl disable mullvad-daemon.service || true
|
|
||||||
systemctl stop mullvad-early-boot-blocking.service || true
|
|
||||||
systemctl disable mullvad-early-boot-blocking.service || true
|
|
||||||
|
|
||||||
mullvad-setup reset-firewall || echo "Failed to reset firewall"
|
mullvad-setup reset-firewall || echo "Failed to reset firewall"
|
||||||
mullvad-setup remove-device || echo "Failed to remove device from account"
|
mullvad-setup remove-device || echo "Failed to remove device from account"
|
||||||
|
|||||||
Reference in New Issue
Block a user