Join GitHub today
pdns_recursor_service_sysvinit behaves different when using Vagrant or Docker as providers #77
Our internal wrapper cookbook has been failing converge after 3.3.1 release.
The reason is that the
The following block part on pdns_recursor_service_sysvinit:
I have been able to reproduce this by simply running a recipe:
And running it with Vagrant and Docker providers (using:
Chef fails in Vagrant, but converges fine with Docker.
@martinisoft the important bytes come when running chef debug.
This is the trace of our internal cookbook (Vagrant), Chef fails to recognize the recursor process (and therefore it decides that it does not exist so it does not stop it). I don't know what happens in Docker because the issue mentioned above
This is the trace when running
A better trace of the wrapper cookbook:
With this round of findings, I have the issue narrowed down and a solution.
The erratic behaviour in docker (and in CentOS, see addendum below) mislead me on thinking that
There is an additional problem on CentOS 6.7 that surfaces only when we try to stop the default pdns-recursor on top on disabling it (see code example below). This which is the simplest and ideal solution to the issue will break tests on CentOS 6.7. This piece of code stops one of the recursors created by
Why this happens?
Stopping the recursor only on debian based distros:
The mix of different behaviours between Centos6.7 (addressed first in 3.3.2 release), Vagrant and Docker has been confused me for the time being and it has not being until a couple of heavy debugging sessions that I've got all the pieces together.