按官网提示是可以安装成功的,但是curl无法使用https下载,会造成下述语句执行失败
# Add Docker's official GPG key:
sudo apt-get update
sudo apt-get install ca-certificates curl
sudo install -m 0755 -d /etc/apt/keyrings
sudo curl -fsSL https://download.docker.com/linux/ubuntu/gpg -o /etc/apt/keyrings/docker.asc
sudo chmod a+r /etc/apt/keyrings/docker.asc# Add the repository to Apt sources:
echo \"deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.asc] https://download.docker.com/linux/ubuntu \$(. /etc/os-release && echo "$VERSION_CODENAME") stable" | \sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
sudo apt-get update
使用以下语句,这将安装所需的软件包以支持通过 HTTPS 进行软件包管理操作。
sudo apt-get install apt-transport-https ca-certificates curl software-properties-common
随后用sudo apt update更新一下,即可。
安装最近的docker 版本:
sudo apt-get install docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin
配置文件 /etc/docker/daemon.json:
配置文件 /etc/docker/daemon.json:
增加配置内容:
{"registry-mirrors": ["https://hub-mirror.c.163.com","https://mirror.ccs.tencentyun.com","https://05f073ad3c0010ea0f4bc00b7105ec20.mirror.swr.myhuaweicloud.com","https://registry.docker-cn.com","https://docker.m.daocloud.io","https://docker.1panel.live","https://hub.rat.dev","https://dockerpull.com","https://dockerproxy.cn","https://docker.rainbond.cc","https://docker.udayun.com","https://docker.211678.top"]
}
systemctl restart docker
检查配置是否生效
docker info
DVWA的新方法:
发现路径:GitHub - OWASP/Top10: Official OWASP Top 10 Document Repository
https://owasp.org/www-project-top-ten/
关注:GitHub - digininja/DVWA: Damn Vulnerable Web Application (DVWA)
docker run --rm -it -p 80:80 vulnerables/web-dvwa