debian

sed -i "s#deb.debian.org#mirrors.aliyun.com#g" /etc/apt/sources.list
sed -i "s#security.debian.org#mirrors.aliyun.com#g" /etc/apt/sources.list

ubuntu

sed -i "s#archive.ubuntu.com#mirrors.aliyun.com#g" /etc/apt/sources.list
sed -i "s#security.ubuntu.com#mirrors.aliyun.com#g" /etc/apt/sources.list

alpline

sed -i "s#dl-cdn.alpinelinux.org#mirrors.aliyun.com#g" /etc/apk/repositories