Skip to content
This repository has been archived by the owner on Mar 6, 2018. It is now read-only.

Commit

Permalink
Merge pull request #15 from opscode/lcg/runit-platform-family
Browse files Browse the repository at this point in the history
platform_family-ization
  • Loading branch information
lamont-granquist committed Feb 15, 2014
2 parents c59beed + 031c02d commit 1f71622
Showing 1 changed file with 14 additions and 6 deletions.
20 changes: 14 additions & 6 deletions files/chef-server-cookbooks/runit/recipes/default.rb
Expand Up @@ -17,16 +17,24 @@
# limitations under the License.
#

# TODO: This needs RHEL support
case node["platform"]
when "ubuntu"
case node["platform_family"]
when "debian"
include_recipe "runit::upstart"
when "redhat","centos","rhel","scientific"
if node['platform_version'] =~ /^6/
when "rhel"
case node["platform"]
when "amazon", "xenserver"
# TODO: platform_version check for old distro without upstart
include_recipe "runit::upstart"
else
include_recipe "runit::sysvinit"
if node['platform_version'] =~ /^5/
include_recipe "runit::sysvinit"
else # >= 6.0
include_recipe "runit::upstart"
end
end
when "fedora"
# TODO: platform_version check for old distro without upstart
include_recipe "runit::upstart"
else
include_recipe "runit::sysvinit"
end

0 comments on commit 1f71622

Please sign in to comment.