poise / supervisor

Development repository for Opscode Cookbook supervisor
Apache License 2.0
64 stars 163 forks source link

init.d script misconfiguration #99

Open danfruehauf opened 8 years ago

danfruehauf commented 8 years ago

init.d script should suid properly to the root user.

Looking at the init script for debian/ubuntu the problem is obvious. At lines: https://github.com/poise/supervisor/blob/master/templates/default/debian/supervisor.init.erb#L95 https://github.com/poise/supervisor/blob/master/templates/default/debian/supervisor.init.erb#L146

You must add -u root -c root -g root, or set it to the proper user.

In my case, when running chef on the node, I get variables propagated from the chef run and it ends up setting $HOME to /home/chef and more.

georgexsh commented 7 years ago

why not use distro shipped package and its init script?

coderanger commented 7 years ago

@georgexsh Because consistency matters when automating. Also this cookbook is effectively deprecated pending rewrite.

georgexsh commented 7 years ago

@coderanger well, meet everyone's needs is impracticable, to me package from distro is best suited.