30 lines
652 B
Bash
30 lines
652 B
Bash
#!/usr/bin/env bash
|
|
set -e
|
|
|
|
echo "================================="
|
|
echo " Runflare Kali Mirror Setup"
|
|
echo "================================="
|
|
|
|
source /etc/os-release
|
|
|
|
if [[ "$ID" != "kali" ]]; then
|
|
echo "This script only supports Kali Linux."
|
|
exit 1
|
|
fi
|
|
|
|
RELEASE=$(lsb_release -cs)
|
|
|
|
echo "[1/3] Backing up sources.list..."
|
|
cp /etc/apt/sources.list /etc/apt/sources.list.bak
|
|
|
|
echo "[2/3] Writing Runflare mirror..."
|
|
|
|
cat > /etc/apt/sources.list <<EOF
|
|
deb https://mirror-linux.runflare.com/kali $RELEASE main non-free contrib
|
|
EOF
|
|
|
|
echo "[3/3] Updating package index..."
|
|
apt update
|
|
|
|
echo "Kali mirror configured."
|