23606487 mcollective's SMF can be simplified
authorAndrew Balfour <Andrew.Balfour@Oracle.COM>
Fri, 09 Sep 2016 15:23:48 -0700
changeset 6877 3174bc3a7842
parent 6876 81ad8e956766
child 6878 252671ed151a
23606487 mcollective's SMF can be simplified 24623788 mcollective 2.8.8 now requires a pidfile
components/ruby/mcollective/files/mcollective
components/ruby/mcollective/files/mcollective.xml
components/ruby/mcollective/mcollective.p5m
--- a/components/ruby/mcollective/files/mcollective	Fri Sep 09 15:19:46 2016 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,28 +0,0 @@
-#!/usr/bin/python2.7
-
-# Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
-#
-#    Licensed under the Apache License, Version 2.0 (the "License"); you may
-#    not use this file except in compliance with the License. You may obtain
-#    a copy of the License at
-#
-#         http://www.apache.org/licenses/LICENSE-2.0
-#
-#    Unless required by applicable law or agreed to in writing, software
-#    distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
-#    WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
-#    License for the specific language governing permissions and limitations
-#    under the License.
-
-import os
-
-import smf_include
-
-
-def start():
-
-    smf_include.smf_subprocess("/usr/sbin/mcollectived")
-
-if __name__ == "__main__":
-    os.putenv("LC_ALL", "C")
-    smf_include.smf_main()
--- a/components/ruby/mcollective/files/mcollective.xml	Fri Sep 09 15:19:46 2016 -0700
+++ b/components/ruby/mcollective/files/mcollective.xml	Fri Sep 09 15:23:48 2016 -0700
@@ -33,7 +33,7 @@
         </dependency>
 
         <exec_method timeout_seconds="60" type="method" name="start"
-            exec="/lib/svc/method/mcollective %m"/>
+            exec="/usr/sbin/mcollectived --pidfile /system/volatile/mcollective.pid"/>
         <exec_method timeout_seconds="60" type="method" name="stop"
             exec=":kill"/>
         <exec_method timeout_seconds="60" type="method" name="refresh"
--- a/components/ruby/mcollective/mcollective.p5m	Fri Sep 09 15:19:46 2016 -0700
+++ b/components/ruby/mcollective/mcollective.p5m	Fri Sep 09 15:23:48 2016 -0700
@@ -46,7 +46,6 @@
 file path=etc/mcollective/rpc-help.erb
 file path=etc/mcollective/server.cfg mode=600 overlay=allow preserve=renamenew
 file files/mcollective.xml path=lib/svc/manifest/application/mcollective.xml
-file files/mcollective path=lib/svc/method/mcollective
 file path=usr/bin/mco
 file path=usr/ruby/$(RUBY_VERSION)/lib/ruby/vendor_ruby/$(RUBY_LIB_VERSION)/mcollective.rb
 file path=usr/ruby/$(RUBY_VERSION)/lib/ruby/vendor_ruby/$(RUBY_LIB_VERSION)/mcollective/agent.rb