initial commit

This commit is contained in:
2026-03-18 03:29:25 +08:00
commit 146c2c5f35
37 changed files with 1445 additions and 0 deletions

View File

@@ -0,0 +1,28 @@
#!/usr/bin/env bash
set -e
echo "================================="
echo " Runflare Alpine Mirror Setup"
echo "================================="
if [[ ! -f /etc/alpine-release ]]; then
echo "This script only supports Alpine."
exit 1
fi
VERSION="v$(cut -d'.' -f1,2 /etc/alpine-release)"
echo "[1/3] Backing up repositories..."
cp /etc/apk/repositories /etc/apk/repositories.bak
echo "[2/3] Writing mirror..."
cat > /etc/apk/repositories <<EOF
http://mirror-linux.runflare.com/alpine/$VERSION/main
http://mirror-linux.runflare.com/alpine/$VERSION/community
EOF
echo "[3/3] Updating package index..."
apk update
echo "Alpine mirror configured."