Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docker: 'compose' is not a docker command. #62

Open
arthurwolf opened this issue Aug 24, 2023 · 6 comments
Open

docker: 'compose' is not a docker command. #62

arthurwolf opened this issue Aug 24, 2023 · 6 comments

Comments

@arthurwolf
Copy link

Running Ubuntu 23.04.

Followed the git README instructions (git clone, cd, docker), I get:

╭─arthur at aquarelle in ~/dev/ai/llama-gpt on master✔ 23-08-24 - 3:47:53
╰─⠠⠵ docker compose up                                                                                                                           on master|✔
docker: 'compose' is not a docker command.
See 'docker --help'
╭─arthur at aquarelle in ~/dev/ai/llama-gpt on master✔ 23-08-24 - 3:48:00
╰─⠠⠵ docker compose -f docker-compose-13b.yml up                                                                                                 on master|✔
unknown shorthand flag: 'f' in -f
See 'docker --help'.

Usage:  docker [OPTIONS] COMMAND

A self-sufficient runtime for containers

Options:
      --config string      Location of client config files (default "/home/arthur/.docker")
  -c, --context string     Name of the context to use to connect to the daemon (overrides DOCKER_HOST env var and default context set with "docker
                           context use")
  -D, --debug              Enable debug mode
  -H, --host list          Daemon socket(s) to connect to
  -l, --log-level string   Set the logging level ("debug"|"info"|"warn"|"error"|"fatal") (default "info")
      --tls                Use TLS; implied by --tlsverify
      --tlscacert string   Trust certs signed only by this CA (default "/home/arthur/.docker/ca.pem")
      --tlscert string     Path to TLS certificate file (default "/home/arthur/.docker/cert.pem")
      --tlskey string      Path to TLS key file (default "/home/arthur/.docker/key.pem")
      --tlsverify          Use TLS and verify the remote
  -v, --version            Print version information and quit

Management Commands:
  builder     Manage builds
  config      Manage Docker configs
  container   Manage containers
  context     Manage contexts
  image       Manage images
  manifest    Manage Docker image manifests and manifest lists
  network     Manage networks
  node        Manage Swarm nodes
  plugin      Manage plugins
  secret      Manage Docker secrets
  service     Manage services
  stack       Manage Docker stacks
  swarm       Manage Swarm
  system      Manage Docker
  trust       Manage trust on Docker images
  volume      Manage volumes

Commands:
  attach      Attach local standard input, output, and error streams to a running container
  build       Build an image from a Dockerfile
  commit      Create a new image from a container's changes
  cp          Copy files/folders between a container and the local filesystem
  create      Create a new container
  diff        Inspect changes to files or directories on a container's filesystem
  events      Get real time events from the server
  exec        Run a command in a running container
  export      Export a container's filesystem as a tar archive
  history     Show the history of an image
  images      List images
  import      Import the contents from a tarball to create a filesystem image
  info        Display system-wide information
  inspect     Return low-level information on Docker objects
  kill        Kill one or more running containers
  load        Load an image from a tar archive or STDIN
  login       Log in to a Docker registry
  logout      Log out from a Docker registry
  logs        Fetch the logs of a container
  pause       Pause all processes within one or more containers
  port        List port mappings or a specific mapping for the container
  ps          List containers
  pull        Pull an image or a repository from a registry
  push        Push an image or a repository to a registry
  rename      Rename a container
  restart     Restart one or more containers
  rm          Remove one or more containers
  rmi         Remove one or more images
  run         Run a command in a new container
  save        Save one or more images to a tar archive (streamed to STDOUT by default)
  search      Search the Docker Hub for images
  start       Start one or more stopped containers
  stats       Display a live stream of container(s) resource usage statistics
  stop        Stop one or more running containers
  tag         Create a tag TARGET_IMAGE that refers to SOURCE_IMAGE
  top         Display the running processes of a container
  unpause     Unpause all processes within one or more containers
  update      Update configuration of one or more containers
  version     Show the Docker version information
  wait        Block until one or more containers stop, then print their exit codes

Run 'docker COMMAND --help' for more information on a command.

To get more help with docker, check out our guides at https://docs.docker.com/go/guides/

╭─arthur at aquarelle in ~/dev/ai/llama-gpt on master✔ 23-08-24 - 3:48:55
╰─⠠⠵ docker compose up                                                                                                                           on master|✔
docker: 'compose' is not a docker command.
See 'docker --help'
╭─arthur at aquarelle in ~/dev/ai/llama-gpt on master✔ 23-08-24 - 3:49:03
╰─⠠⠵       

Any idea what I'm doing wrong?

@nmfretz
Copy link
Contributor

nmfretz commented Aug 24, 2023

Hi @arthurwolf, it looks like you may be facing one of two issues.

  1. You don't have Docker Compose installed. If that's the case then you'll first need to install it before you can run docker compose up. To find out if you have Docker Compose installed, run docker compose --version in your terminal. If a version number is returned then you have it installed.

  2. You have Docker Compose Standalone installed, in which case the syntax you should use is docker-compose up. Note the hyphen. To find out if you have Standalone installed, run docker-compose --version

Let me know if you get it sorted!

@arthurwolf
Copy link
Author

╭─arthur at aquarelle in ~ 23-08-24 - 18:26:48
╰─○ docker compose --version
Docker version 20.10.25, build 20.10.25-0ubuntu1~23.04.1

Looks like that worked, thanks!

╭─arthur at aquarelle in ~/dev/ai/llama-gpt on master✔ 23-08-24 - 18:27:46
╰─⠠⠵ docker-compose up                                              on master|✔
Creating network "llama-gpt_default" with the default driver
Pulling llama-gpt-api-7b (ghcr.io/abetlen/llama-cpp-python:latest)...
latest: Pulling from abetlen/llama-cpp-python
14726c8f7834: Pull complete
7d676dc8a994: Pull complete
e9e2f08137fc: Pull complete
6cc9fece80c8: Pull complete
264b6a89a95d: Pull complete
50872ae560f9: Downloading [====>                                              ]  12.28MB/140MB
5ab61a038675: Download complete
4f4fb700ef54: Download complete
124cd1deda15: Download complete
23e537c28460: Download complete
c904885da53b: Download complete

Might be worth some kind of docs edit? Not sure how rare my situation is.

@rsebi
Copy link

rsebi commented Aug 24, 2023

╭─arthur at aquarelle in ~ 23-08-24 - 18:26:48
╰─○ docker compose --version
Docker version 20.10.25, build 20.10.25-0ubuntu1~23.04.1

Looks like that worked, thanks!

╭─arthur at aquarelle in ~/dev/ai/llama-gpt on master✔ 23-08-24 - 18:27:46
╰─⠠⠵ docker-compose up                                              on master|✔
Creating network "llama-gpt_default" with the default driver
Pulling llama-gpt-api-7b (ghcr.io/abetlen/llama-cpp-python:latest)...
latest: Pulling from abetlen/llama-cpp-python
14726c8f7834: Pull complete
7d676dc8a994: Pull complete
e9e2f08137fc: Pull complete
6cc9fece80c8: Pull complete
264b6a89a95d: Pull complete
50872ae560f9: Downloading [====>                                              ]  12.28MB/140MB
5ab61a038675: Download complete
4f4fb700ef54: Download complete
124cd1deda15: Download complete
23e537c28460: Download complete
c904885da53b: Download complete

Might be worth some kind of docs edit? Not sure how rare my situation is.

The expectation is that you know docker & docker compose. But a slight edit to the doc would be appreciated as pointed.

@arthurwolf
Copy link
Author

arthurwolf commented Aug 24, 2023

Thanks a lot for all the help.

(I'll make a PR with the docs change)

Ok so it works now, but I have a second issue, asking here just in case it's easy, I'll make a new issue if not.

so I started with

docker-compose up

It worked.

So I wanted to try 13b next, so I did:

docker-compose down

Which worked, and then:

docker-compose -f docker-compose-13b.yml up 

But this gets me:

╰─⠠⠵ docker-compose -f docker-compose-13b.yml up                                                                                                                                                                      on master|✔
Starting llama-gpt_llama-gpt-api-13b_1 ... 
Starting llama-gpt_llama-gpt-api-13b_1 ... error

ERROR: for llama-gpt_llama-gpt-api-13b_1  Cannot start service llama-gpt-api-13b: network c6ea4bb425bd91c6090bfde1ef50c974ada03f2bfba27caff216184c6684a5d1 not found

ERROR: for llama-gpt-api-13b  Cannot start service llama-gpt-api-13b: network c6ea4bb425bd91c6090bfde1ef50c974ada03f2bfba27caff216184c6684a5d1 not found
ERROR: Encountered errors while bringing up the project.

Which I'm not sure what to do about...

The expectation is that you know docker & docker compose

I use docker a few dozen times a year, I've even made a few containers, but I'm not sure what's the criteria for "knowing" docker, this is my first time running into this one.

@arthurwolf
Copy link
Author

@maxnatt
Copy link

maxnatt commented Aug 30, 2023

As I mentioned in #81, Compose V1 is officially EoL and I think a proper solution would be simply to advice users to ensure they are using Compose V2: https://docs.docker.com/compose/install/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants