--- /dev/null
+case node['platform']
+when 'ubuntu'
+ default["ceph"]["mon"]["init_style"] = "upstart"
+else
+ default["ceph"]["mon"]["init_style"] = "sysvinit"
+end
--- /dev/null
+case node['platform']
+when 'ubuntu'
+ default["ceph"]["osd"]["init_style"] = "upstart"
+else
+ default["ceph"]["osd"]["init_style"] = "sysvinit"
+end
state = JSON.parse(mon_status)['state']
return QUORUM_STATES.include?(state)
end
-
-def service_type()
- case node['platform']
- when 'ubuntu'
- return "upstart"
- else
- return "sysvinit"
- end
-end
include_recipe "ceph::default"
include_recipe "ceph::conf"
-service_type = service_type()
+service_type = node["ceph"]["mon"]["init_style"]
service "ceph_mon" do
case service_type
when "upstart"
end
end
-service_type = service_type()
+service_type = node["ceph"]["osd"]["init_style"]
service "ceph_osd" do
case service_type
when "sysvinit"