"launcher rebuild" fails because of "ip addr show docker0"

(Julien) #1

I just tried to rebuild my container and hit the following error :

# ./launcher rebuild myforum
Ensuring launcher is up to date
Fetching origin
Launcher is up-to-date
Stopping old container
+ /usr/bin/docker.io stop -t 10 myforum
cd /pups && git pull && /pups/bin/pups --stdin
Unable to find image '' locally
Pulling repository
FATA[0001] Error: image library/ not found 
cat: cids/myforum_bootstrap.cid: No such file or directory
docker: "rm" requires a minimum of 1 argument. See '/usr/bin/docker.io rm --help'.
rm: cannot remove ‘cids/myforum_bootstrap.cid’: No such file or directory
** FAILED TO BOOTSTRAP ** please scroll up and look for earlier error messages, there may be more than one

I tracked this down to launcher#L78-L80

On my machine I get :

$ ip addr show docker0
3: docker0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP group default 
    link/ether 56:84:7a:fe:97:99 brd ff:ff:ff:ff:ff:ff
    inet scope global docker0
       valid_lft forever preferred_lft forever
    inet scope global docker0
       valid_lft forever preferred_lft forever

$ ip addr show docker0 |grep 'inet ' | awk '{ split($2,a,"/"); print a[1] }'

which makes the launcher#L499 line fail badly with the cryptic error message above :

Here are some info about my system :

$ lsb_release -a
No LSB modules are available.
Distributor ID:	Ubuntu
Description:	Ubuntu 14.04.4 LTS
Release:	14.04
Codename:	trusty

$ aptitude show docker.io  | grep ^Version
Version: 1.6.2~dfsg1-1ubuntu4~14.04.1

docker is used exclusively to run discourse.
I’m using discourse since more than a year, and have successfullly run launcher rebuild in the past. I just hit this issue today, trying to update my container.

(Jeff Atwood) #2

Is this because your Docker version is so old at 1.6? I suggest updating Docker.

(Julien) #3

Updating docker to 1.11 was painful but fixes this.

but maybe the ip / grep / awk magic requires some extra security to avoid the strange message long after.

(Jeff Atwood) #4

OK, good to know – I will make “minimum required docker verson” 1.8 for launcher (it was previously 1.6) right now, and see if that helps anyone in the future.

(Jeff Atwood) #5