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 issue during hab export #863

Closed
mostafahussein opened this issue Jun 15, 2016 · 9 comments
Closed

docker issue during hab export #863

mostafahussein opened this issue Jun 15, 2016 · 9 comments

Comments

@mostafahussein
Copy link

I am following the tutorial steps and currently i am on this step:

[default:/src:0]# hab pkg export docker myorigin/mytutorialapp

and i am getting the following error

★ Install of core/hab-sup complete with 12 packages installed.
» Symlinking hab from core/hab into /tmp/hab-pkg-dockerize-dylO/rootfs/hab/bin
★ Binary hab from core/hab/0.7.0/20160614230104 symlinked to /tmp/hab-pkg-dockerize-dylO/rootfs/hab/bin/hab
» Symlinking bash from core/busybox-static into /tmp/hab-pkg-dockerize-dylO/rootfs/bin
★ Binary bash from core/busybox-static/1.24.2/20160612081725 symlinked to /tmp/hab-pkg-dockerize-dylO/rootfs/bin/bash
» Symlinking sh from core/busybox-static into /tmp/hab-pkg-dockerize-dylO/rootfs/bin
★ Binary sh from core/busybox-static/1.24.2/20160612081725 symlinked to /tmp/hab-pkg-dockerize-dylO/rootfs/bin/sh
Error response from daemon: client is newer than server (client API version: 1.23, server API version: 1.22)

  • how should i solve it ?
@mostafahussein
Copy link
Author

I am updating docker on the host, will update and close the issue if this will solve it for me

@davidwrede
Copy link

FWIW, I had the same issue in the past and upgrading Docker worked for me.

@mostafahussein
Copy link
Author

Now i am getting another issue:

Cannot connect to the Docker daemon. Is the docker daemon running on this host?

However docker service is running on the host, i am using fedora

Redirecting to /bin/systemctl status  docker.service
● docker.service - Docker Application Container Engine
   Loaded: loaded (/usr/lib/systemd/system/docker.service; enabled; vendor preset: disabled)
   Active: active (running) since Wed 2016-06-15 18:49:50 EET; 8min ago
     Docs: https://docs.docker.com
 Main PID: 24269 (docker)
   Memory: 14.7M
   CGroup: /system.slice/docker.service
           ├─24269 /usr/bin/docker daemon -H fd://
           └─24291 docker-containerd -l /var/run/docker/libcontainerd/docker-containerd.sock --runtime docker-runc --start-timeout 2m

Jun 15 18:49:49 s0ny-v4io docker[24269]: time="2016-06-15T18:49:49.335988871+02:00" level=info msg="Graph migration to content-addressability took 0.00 seconds"
Jun 15 18:49:49 s0ny-v4io docker[24269]: time="2016-06-15T18:49:49.347797429+02:00" level=info msg="Firewalld running: true"
Jun 15 18:49:49 s0ny-v4io docker[24269]: time="2016-06-15T18:49:49.728205637+02:00" level=info msg="Default bridge (docker0) is assigned with an IP address...P address"
Jun 15 18:49:50 s0ny-v4io docker[24269]: time="2016-06-15T18:49:50.012280446+02:00" level=info msg="Loading containers: start."
Jun 15 18:49:50 s0ny-v4io docker[24269]: ..
Jun 15 18:49:50 s0ny-v4io docker[24269]: time="2016-06-15T18:49:50.060925003+02:00" level=info msg="Loading containers: done."
Jun 15 18:49:50 s0ny-v4io docker[24269]: time="2016-06-15T18:49:50.060993648+02:00" level=info msg="Daemon has completed initialization"
Jun 15 18:49:50 s0ny-v4io docker[24269]: time="2016-06-15T18:49:50.061087823+02:00" level=info msg="Docker daemon" commit=b9f10c9 graphdriver=devicemapper ...ion=1.11.2
Jun 15 18:49:50 s0ny-v4io docker[24269]: time="2016-06-15T18:49:50.071659695+02:00" level=info msg="API listen on /var/run/docker.sock"
Jun 15 18:49:50 s0ny-v4io systemd[1]: Started Docker Application Container Engine.
Hint: Some lines were ellipsized, use -l to show in full.

@mostafahussein
Copy link
Author

mostafahussein commented Jun 15, 2016

I think its about the docker api, i guess i faced this issue once before and it was something to do with the docker init script, but i cannot remember what i have done before

@davidwrede
Copy link

davidwrede commented Jun 15, 2016

I've seen comments for this on SO to add yourself to the docker group, stop/start the Docker service, etc.

The tutorial has you export to Docker to show how easy it is to export a Habitat package into another runtime format, but if you're running on Linux, you can start the Habitat service directly. Check out the instructions on Run packages on how to do that.

@mostafahussein
Copy link
Author

for the usermod part i already made it. but do you think that runing habitat as a service will fix this issue ?

@davidwrede
Copy link

Running natively won't fix the Docker issue, but it will show you how a Habitat service starts up and runs.

@mostafahussein
Copy link
Author

I cant figure out how habitat interacting with docker.
for example i have tried the following and i can use the API without problems. but in case of habitat i don't know if it tries to connect to a specific port or it try to connect through another way. do you have any information ?

@mostafahussein
Copy link
Author

solved by adding the root to docker grp. i didn't notice that habitat was using the root not my user. thanks david

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

2 participants