安装docker
# 一键安装脚本
sudo curl -fsSL https://get.docker.com | sh
安装后检查是否安装成功,出现版本号说明成功了
======================
`docker -v
`
安装docker compose
# v2.16.0可以换成你想安装的版本
# /usr/local/bin/docker-compose也可以换成/usr/bin/docker-compose
curl -L https://github.com/docker/compose/releases/download/v2.16.0/docker-compose-`uname -s`-`uname -m` > /usr/local/bin/docker-compose
# 或者
curl -L https://github.com/docker/compose/releases/download/v2.16.0/docker-compose-`uname -s`-`uname -m` > /usr/bin/docker-compose
修改权限
====
chmod +x /usr/local/bin/docker-compose
或者
===
chmod +x /usr/bin/docker-compose
安装后检查是否安装成功,出现版本号说明成功了
======================
`docker-compose -v
`