chef-provisioning-docker
chef-provisioning-docker copied to clipboard
Proxy thread unable to start: Address already in use
I am trying to run the example piece of code given for chef-provisioning-docker using chef zero. When I try to run it appears that Chef is already listening on port 172.17.0.1 port 8889 and causing the code the inability to use 172.17.0.1 to communicate from the container to the host. Is there something I need to do to resolve this issue?
Output: Starting Chef Client, version 12.9.38 ...
-
machine_image[ssh_server] action create
-
update node ssh_server at chefzero://localhost:8889 ... [2016-04-24T20:09:07-06:00] ERROR: Proxy thread unable to start: Address already in use - bind(2) for "172.17.0.1" port 8889
[ssh_server] [2016-04-25T02:09:19+00:00] INFO: Forking chef instance to converge... [2016-04-25T02:09:19+00:00] INFO: *** Chef 12.9.38 *** [2016-04-25T02:09:19+00:00] INFO: Platform: x86_64-linux [2016-04-25T02:09:19+00:00] INFO: Chef-client pid: 317
================================================================================ Chef encountered an error attempting to load the node data for "ssh_server" ================================================================================ Unexpected Error: ----------------- Errno::EHOSTUNREACH: No route to host - connect(2) for "172.17.0.1" port 8889
Code Run:
require 'chef/provisioning/docker_driver'
machine_image 'ssh_server' do recipe 'openssh' machine_options :docker_options => { :base_image => { :name => 'ubuntu', :repository => 'ubuntu', :tag => '14.04' } } end
machine 'ssh00' do from_image 'ssh_server' machine_options :docker_options => { :command => '/usr/sbin/sshd -D -o UsePAM=no -o UsePrivilegeSeparation=no -o PidFile=/tmp/sshd.pid', :ports => [22] } end
Software/Hardware Specs: Operating System: CentOS Linux 7 (Core) Kernel: Linux 3.10.0-327.13.1.el7.x86_64 Operating System: centos-release-7.2.1511.el7.cl chef-client-version: 12.9.38 docker-version: 1.9.1, build 78ee77d/1.9.1 Gems using: chef-provisioning (1.7.0) chef-provisioning-docker (0.9.0) docker-api (~> 1.26, >= 1.26.2)
👍