move ct_deletion

This commit is contained in:
Michel Roegl-Brunner 2025-05-15 16:06:06 +02:00
parent a7cc9a39ca
commit bc001ed6e3
2 changed files with 10 additions and 8 deletions

View File

@ -40,3 +40,12 @@ description
msg_ok "Completed Successfully!\n"
echo -e "${CREATING}${GN}${APP} setup has been successfully initialized!${CL}"
read -p "Remove this Container? <y/N> " prompt
if [[ "${prompt,,}" =~ ^(y|yes)$ ]]; then
pct stop "$CTID"
pct destroy "$CTID"
msg_ok "Removed this script"
else
msg_warn "Did not remove this script"
fi

View File

@ -1428,14 +1428,7 @@ EOF
systemctl start ping-instances.service
fi
read -p "Remove this Container? <y/N> " prompt
if [[ "${prompt,,}" =~ ^(y|yes)$ ]]; then
pct stop "$CTID"
pct destroy "$CTID"
msg_ok "Removed this script"
else
msg_warn "Did not remove this script"
fi
post_update_to_api "done" "none"
}