#!/usr/bin/env bash set -e echo "=================================" echo " Liara Alpine Mirror Setup" echo "=================================" if [[ ! -f /etc/alpine-release ]]; then echo "This script only supports Alpine Linux." exit 1 fi echo echo "[1/3] Backing up repositories..." cp /etc/apk/repositories /etc/apk/repositories.bak echo echo "[2/3] Detecting Alpine version..." ALPINE_VERSION=$(cut -d'.' -f1,2 /etc/alpine-release) echo "Detected Alpine version: $ALPINE_VERSION" echo echo "[3/3] Writing Liara mirror..." cat > /etc/apk/repositories <