Debian系统
去清华园找源
https://mirrors.tuna.tsinghua.edu.cn/help/debian/
apt update #安装软件前需要先更新索引
apt install procps #提供top,ps,free等命令
apt install psmisc #提供pstree,killall等命令
apt install iputils-ping #提供ping命令
apt install net-tools #提供netstat网络工具等
查看版本
root@8615451f9fcf:/etc# cat /etc/os-release
PRETTY_NAME="Debian GNU/Linux 11 (bullseye)"
NAME="Debian GNU/Linux"
VERSION_ID="11"
VERSION="11 (bullseye)"
VERSION_CODENAME=bullseye
ID=debian
HOME_URL="https://www.debian.org/"
SUPPORT_URL="https://www.debian.org/support"
BUG_REPORT_URL="https://bugs.debian.org/"
echo "deb https://mirrors.tuna.tsinghua.edu.cn/debian/ bullseye main contrib non-free" >> /etc/apt/sources.list
echo "deb https://mirrors.tuna.tsinghua.edu.cn/debian/ bullseye-updates main contrib non-free" >> /etc/apt/sources.list
echo "deb https://mirrors.tuna.tsinghua.edu.cn/debian/ bullseye-backports main contrib non-free" >> /etc/apt/sources.list
echo "deb https://mirrors.tuna.tsinghua.edu.cn/debian-security bullseye-security main contrib non-free" >> /etc/apt/sources.list
apt update
根据需要安装东西
apt-get install -y iproute2
apt-get install -y vim
apt install iputils-ping -y
alpine镜像,不能前台保存的测试
[root@za-proxy-active docker]# docker run -ti alpine sh
sed -i 's/dl-cdn.alpinelinux.org/mirrors.tuna.tsinghua.edu.cn/g' /etc/apk/repositories
apk update
apk add vim