Docker: command not found

2.0

#1

I’m a bit confused on what’s going on with docker.

Whenever I make a simple call for docker info, my build fails:

At first I assumed it had something to do with docker’s installation and so I tried explicitly installing it in my project, but still got the same error. Here is what I included in the steps:
apt-get update apt-get install -y wget apt-get install -y --force-yes apt-transport-https apt-key adv --keyserver hkp://p80.pool.sks-keyservers.net:80 --recv-keys 58118E89F3A912897C070ADBF76221572C52609D sh -c "wget -qO- https://get.docker.io/gpg | apt-key add -" sh -c "echo deb http://get.docker.io/ubuntu docker main > /etc/apt/sources.list.d/docker.list" apt-get update apt-get install -y docker

What I then tried was to modify the permissions with
usermod -aG docker root, but this error was thrown
usermod: group 'docker' does not exist Exited with code 6

I rebuilt everything with SSH, and wanted to check whether docker was already installed within this environment. Even though the docker command was not found, I tried installing docker with apt-get install docker, but apparently docker was already updated to the newest version…meaning docker does exist on my system…what is going on?

root@ff38e3ba5282:~# docker bash: docker: command not found root@ff38e3ba5282:~# root docker bash: root: command not found root@ff38e3ba5282:~# apt-get install docker Reading package lists... Done Building dependency tree Reading state information... Done docker is already the newest version.


#2

I think you just list it as a dependency in your circle.yml file. E.g. …

machine:
  node:
    version: 5.8.0
  services:
    - docker

#3

this only works for circleci version 1


#4

How is there no solution to this yet? I’m severely disappointed with just about everything CircleCI 2.0 - Mostly the documentation but if this was better I’m sure I’d have fewer complaints.


#5

You need to install it. If you’re not using an image we provide, it probably doesn’t have Docker installed. That is the nature of containers.


#6