0

docker pull www.alm-docker-registry.com:8090/test... is working but when i am trying to do the same thing using puppet script, its showing error.

Notice: /Stage[main]/Main/Exec[Pulling Docker Image]/returns: 2015/01/30 11:11:11 Authentication is required.
Error: /usr/bin/docker pull www.alm-docker-registry.com:8090/test... returned 1 instead of one of [0]
Error: /Stage[main]/Main/Exec[Pulling Docker Image]/returns: change from notrun to 0 failed: /usr/bin/docker pull www.alm-docker-registry.com:8090/test... returned 1 instead of one of [0]

Note: I am not using any module but directly executing commands from manifest.

exec{'Pulling Docker Image':  
      command=>"/usr/bin/docker pull www.alm-docker-registry.com:8090/test... ,  
 }`
shauryachats
  • 9,975
  • 4
  • 35
  • 48
abhishk02
  • 13
  • 3

1 Answers1

0

If you look at the error, it's saying that Authentication is required.. This could be the user that Puppet is running the docker exec as has different permissions that your default user.

Have you thought about using the Docker module? It means you can perform the actions you want with, plus there's a lot of community support, and it makes the Docker actions idempotent so you won't get the commands running multiple times if not needed.

Peter Souter
  • 5,110
  • 1
  • 33
  • 62