无法在 Linux 中安装 Docker compose

Blo*_*per 5 linux

我无法在 Linux 系统上安装 docker compose。运行安装命令后出现以下错误:

~$ sudo apt-get -f install docker-compose
Reading package lists... Done
Building dependency tree
Reading state information... Done
You might want to run 'apt-get -f install' to correct these:
The following packages have unmet dependencies:
 code : Depends: libnotify4 but it is not going to be installed
        Depends: libnss3 but it is not going to be installed
        Depends: libxkbfile1 but it is not going to be installed
        Depends: libgconf-2-4 but it is not going to be installed
        Depends: libsecret-1-0 but it is not going to be installed
 docker-compose : Depends: python-cached-property but it is not going to be installed
                  Depends: python-docker (>= 1.9.0) but it is not going to be installed
                  Depends: python-dockerpty (>= 0.4.1) but it is not going to be installed
                  Depends: python-docopt but it is not going to be installed
                  Depends: python-enum34 but it is not going to be installed
                  Depends: python-jsonschema but it is not going to be installed
                  Depends: python-requests (>= 2.6.1) but it is not going to be installed
                  Depends: python-six (>= 1.3.0) but it is not going to be installed
                  Depends: python-texttable but it is not going to be installed
                  Depends: python-websocket but it is not going to be installed
                  Depends: python-yaml but it is not going to be installed
E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution).
Run Code Online (Sandbox Code Playgroud)

有人可以帮我吗?我也尝试过 sudo apt-get clean 但没有用

Ign*_*lán 6

我认为安装 docker-compose 最简单的方法是通过 pip:

sudo apt-get install python-pip
sudo pip install docker-compose
Run Code Online (Sandbox Code Playgroud)