added convenience property 'config/method_prefix' defaulting to '/opt/custom/bin' to both services

This commit is contained in:
Tamás Gérczei 2016-04-19 09:34:42 +02:00
parent 711946cb72
commit 85ed1160fd
2 changed files with 7 additions and 3 deletions

View File

@ -10,11 +10,14 @@
<dependent name='zones' grouping='require_all' restart_on='none'>
<service_fmri value='svc:/system/zones'/>
</dependent>
<exec_method name='start' type='method' exec='/opt/custom/bin/svc-guesthandler disarm' timeout_seconds='0'/>
<exec_method name='start' type='method' exec='%{config/method_prefix}/svc-guesthandler disarm' timeout_seconds='0'/>
<exec_method name='stop' type='method' exec=':true' timeout_seconds='100'/>
<property_group name='startd' type='framework'>
<propval name='duration' type='astring' value='transient'/>
</property_group>
<property_group name='config' type='eu.gerczei,guesthandler_configuration'>
<propval name='method_prefix' type='astring' value='/opt/custom/bin'/>
</property_group>
<stability value='Unstable'/>
<template>
<common_name>

View File

@ -7,19 +7,20 @@
<dependency name='vmadmd' grouping='require_all' restart_on='none' type='service'>
<service_fmri value='svc:/system/smartdc/vmadmd:default'/>
</dependency>
<exec_method name='start' type='method' exec='/opt/custom/bin/svc-guesthandler %m' timeout_seconds='0'>
<exec_method name='start' type='method' exec='%{config/method_prefix}/svc-guesthandler %m' timeout_seconds='0'>
<method_context>
<method_environment>
<envvar name='DELAY' value='%{config/delay}'/>
</method_environment>
</method_context>
</exec_method>
<exec_method name='stop' type='method' exec='/opt/custom/bin/svc-guesthandler %m' timeout_seconds='0'/>
<exec_method name='stop' type='method' exec='%{config/method_prefix}/svc-guesthandler %m' timeout_seconds='0'/>
<property_group name='startd' type='framework'>
<propval name='duration' type='astring' value='transient'/>
</property_group>
<property_group name='config' type='eu.gerczei,guesthandler_configuration'>
<propval name='delay' type='integer' value='30'/>
<propval name='method_prefix' type='astring' value='/opt/custom/bin'/>
</property_group>
<stability value='Unstable'/>
<template>