🐡

Ubuntu 20.04にdocker compose v2.2.2を導入

2021/12/25に公開

タイトル通り。公式ドキュメントに従って入れるだけのメモ。
https://docs.docker.com/compose/cli-command/

$ mkdir -p ~/.docker/cli-plugins/
$ curl -SL https://github.com/docker/compose/releases/download/v2.2.2/docker-compose-linux-x86_64 -o ~/.docker/cli-plugins/docker-compose
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100   664  100   664    0     0   2423      0 --:--:-- --:--:-- --:--:--  2414
100 23.5M  100 23.5M    0     0  1291k      0  0:00:18  0:00:18 --:--:-- 4234k

$ chmod +x ~/.docker/cli-plugins/docker-compose
$ docker compose version
Docker Compose version v2.2.2

v1と変換してくれるCompose Switchなるものもあったのでついでに入れておく

$ curl -fL https://raw.githubusercontent.com/docker/compose-cli/main/scripts/install/install_linux.sh | sh
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100  5982  100  5982    0     0  15417      0 --:--:-- --:--:-- --:--:-- 15417Running checks...

Checks passed!
Downloading CLI...
Downloaded CLI!
Installing CLI...
Done!

Discussion