Files
cloud-host/backend/helm/cloudhost-ceph/scripts/uninstall.sh
T
keyhan ee5bd0a291 Add Harbor/Ceph runbooks and align single-node Ceph docs with abr deployment.
Document registry ingress split, image mirroring, loop OSD setup, and platform integration paths.
2026-07-01 00:22:06 +03:30

27 lines
766 B
Bash
Executable File

#!/usr/bin/env bash
# Remove CloudHost extras + Rook cluster + operator (DATA LOSS).
set -euo pipefail
read -r -p "This deletes ALL Ceph data. Type 'delete-ceph' to continue: " CONFIRM
if [[ "${CONFIRM}" != "delete-ceph" ]]; then
echo "Aborted."
exit 1
fi
helm uninstall cloudhost-ceph -n cloudhost-builds 2>/dev/null || true
helm uninstall rook-ceph-cluster -n rook-ceph 2>/dev/null || true
helm uninstall rook-ceph -n rook-ceph 2>/dev/null || true
echo "Waiting for Rook resources to terminate..."
sleep 15
kubectl -n rook-ceph get pods 2>/dev/null || true
cat <<'EOF'
IMPORTANT: On each node, wipe Rook state before reinstalling:
sudo rm -rf /var/lib/rook
sudo rm -rf /var/lib/rook/osd
For raw-disk OSDs also zap disks (see RUNBOOK-CEPH.fa.md).
EOF