Supervisor - which cookbook?


#1

Good day.

I’m trying to use supervisord within a Docker container (bootstrapped with Chef) and just wanted to know what version/source of supervisord cookbook is the most stable/recommended to use?

(The base OS on which Docker will be running will be Oracle Linux 6.7)

I see I have the following options:

  1. https://github.com/poise/supervisor - v0.4.10 - build seems to be failing which is a bit worrying?

  2. https://supermarket.chef.io/cookbooks/supervisord - v1.0.1 - Not sure if OEL 6.7 is supported, the page lists support for Debian and Ubuntu?

  3. ?

Thanks for your help!


#2

You probably just want to use the Docker cookbook.

https://supermarket.chef.io/cookbooks/docker

The Docker service wants to be the supervisor for the containers it manages.
Check out the restart_policy property.

docker_container 'try_try_again' do
  repo 'alpine'
  tag '3.1'
  command 'grep asdasdasd /etc/passwd'
  restart_policy 'on-failure'
  restart_maximum_retry_count 2
  action :run_if_missing
end

#3

Number 1 is mine and is in the process of being deprecated. It will be replaced internally by https://github.com/poise/poise-supervisor and the supervisor cookbook will be converted to a compat wrapper (like what I just did with monit and poise-monit). Stay tuned for the release, probably next week-ish.


#4

Thanks @someara ; this is for running services within a Docker container (chef-client is running within the Docker container). I believe the docker cookbook is for controlling Docker containers themselves (i.e. chef is installed on the host along with Docker) as opposed to chef running inside Docker.

Thanks @coderanger, I will await the refresh.


#5

Hi @coderanger

Has poise-supervisor now been updated? https://github.com/poise/poise-supervisor shows files from last year, therefore checking, thanks!

Regards
Aravind