Remove old temp service first
Removes any leftover temp update service if they exist
This commit is contained in:
@@ -20,7 +20,13 @@ remount_rw() {
|
|||||||
remount_ro() {
|
remount_ro() {
|
||||||
mount -o remount,ro /
|
mount -o remount,ro /
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# Installation Prep
|
||||||
remount_rw
|
remount_rw
|
||||||
|
systemctl daemon-reload
|
||||||
|
rm $SERVICE_FILE
|
||||||
|
rm $SERVICE_NAME
|
||||||
|
|
||||||
# Create the systemd service file
|
# Create the systemd service file
|
||||||
cat <<EOF > "$SERVICE_FILE"
|
cat <<EOF > "$SERVICE_FILE"
|
||||||
[Unit]
|
[Unit]
|
||||||
@@ -75,7 +81,7 @@ uninstall_simpleadmin() {
|
|||||||
rm -rf "$SIMPLE_ADMIN_DIR"
|
rm -rf "$SIMPLE_ADMIN_DIR"
|
||||||
rm -f /lib/systemd/system/ttyd.service
|
rm -f /lib/systemd/system/ttyd.service
|
||||||
rm -f /lib/systemd/system/multi-user.target.wants/ttyd.service
|
rm -f /lib/systemd/system/multi-user.target.wants/ttyd.service
|
||||||
rm -rf /bin/ttyd
|
rm -f /bin/ttyd
|
||||||
echo -e "\e[1;32mttyd has been uninstalled.\e[0m"
|
echo -e "\e[1;32mttyd has been uninstalled.\e[0m"
|
||||||
|
|
||||||
echo "Uninstallation process completed."
|
echo "Uninstallation process completed."
|
||||||
|
|||||||
Reference in New Issue
Block a user