1 | <?xml version="1.0"?>
|
---|
2 | <!DOCTYPE service_bundle SYSTEM "/usr/share/lib/xml/dtd/service_bundle.dtd.1">
|
---|
3 | <!--
|
---|
4 | # Sun VirtualBox
|
---|
5 | # Solaris SMF service manifest for VirtualBox webservice server.
|
---|
6 | # $Id$
|
---|
7 |
|
---|
8 | Copyright (C) 2008-2009 Oracle Corporation
|
---|
9 |
|
---|
10 | This file is part of VirtualBox Open Source Edition (OSE), as
|
---|
11 | available from http://www.virtualbox.org. This file is free software;
|
---|
12 | you can redistribute it and/or modify it under the terms of the GNU
|
---|
13 | General Public License (GPL) as published by the Free Software
|
---|
14 | Foundation, in version 2 as it comes in the "COPYING" file of the
|
---|
15 | VirtualBox OSE distribution. VirtualBox OSE is distributed in the
|
---|
16 | hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
|
---|
17 | -->
|
---|
18 |
|
---|
19 | <service_bundle type='manifest' name='SUNWvbox:webservice'>
|
---|
20 |
|
---|
21 | <service
|
---|
22 | name='application/virtualbox/webservice'
|
---|
23 | type='service'
|
---|
24 | version='1'>
|
---|
25 |
|
---|
26 | <single_instance />
|
---|
27 |
|
---|
28 | <dependency
|
---|
29 | name='fs-local'
|
---|
30 | grouping='require_all'
|
---|
31 | restart_on='none'
|
---|
32 | type='service'>
|
---|
33 | <service_fmri value='svc:/system/filesystem/local' />
|
---|
34 | </dependency>
|
---|
35 |
|
---|
36 | <dependency
|
---|
37 | name='network-service'
|
---|
38 | grouping='require_all'
|
---|
39 | restart_on='none'
|
---|
40 | type='service'>
|
---|
41 | <service_fmri value='svc:/network/service' />
|
---|
42 | </dependency>
|
---|
43 |
|
---|
44 | <dependency
|
---|
45 | name='name-services'
|
---|
46 | grouping='require_all'
|
---|
47 | restart_on='refresh'
|
---|
48 | type='service'>
|
---|
49 | <service_fmri value='svc:/milestone/name-services' />
|
---|
50 | </dependency>
|
---|
51 |
|
---|
52 | <instance name='default' enabled='false'>
|
---|
53 |
|
---|
54 | <dependent
|
---|
55 | name='virtualbox-webservice_multi-user'
|
---|
56 | grouping='optional_all'
|
---|
57 | restart_on='none'>
|
---|
58 | <service_fmri value='svc:/milestone/multi-user' />
|
---|
59 | </dependent>
|
---|
60 |
|
---|
61 | <exec_method
|
---|
62 | type='method'
|
---|
63 | name='start'
|
---|
64 | exec='/opt/VirtualBox/smf-vboxwebsrv.sh %m'
|
---|
65 | timeout_seconds='15'>
|
---|
66 | <method_context>
|
---|
67 | <method_credential user='root' group='root' />
|
---|
68 | </method_context>
|
---|
69 | </exec_method>
|
---|
70 |
|
---|
71 | <exec_method
|
---|
72 | type='method'
|
---|
73 | name='stop'
|
---|
74 | exec=':kill'
|
---|
75 | timeout_seconds='15'>
|
---|
76 | <method_context>
|
---|
77 | <method_credential user='root' group='root' />
|
---|
78 | </method_context>
|
---|
79 | </exec_method>
|
---|
80 |
|
---|
81 | <property_group name='startd' type='framework'>
|
---|
82 | <!-- The default contract restarter behavior is not appropriate,
|
---|
83 | it will kill VMs if the service is restarted. -->
|
---|
84 | <propval name='duration' type='astring' value='child' />
|
---|
85 | <!-- sub-process core dumps/signals shouldn't restart session -->
|
---|
86 | <propval name='ignore_error' type='astring' value='core,signal' />
|
---|
87 | </property_group>
|
---|
88 |
|
---|
89 | <property_group name='config' type='application'>
|
---|
90 | <propval name='user' type='astring' value='root' />
|
---|
91 | <propval name='host' type='astring' value='localhost' />
|
---|
92 | <propval name='port' type='integer' value='18083' />
|
---|
93 | </property_group>
|
---|
94 |
|
---|
95 | <template>
|
---|
96 | <common_name>
|
---|
97 | <loctext xml:lang='C'>
|
---|
98 | VirtualBox Webservice
|
---|
99 | </loctext>
|
---|
100 | </common_name>
|
---|
101 | </template>
|
---|
102 |
|
---|
103 | </instance>
|
---|
104 |
|
---|
105 | <stability value='External' />
|
---|
106 |
|
---|
107 | </service>
|
---|
108 |
|
---|
109 | </service_bundle>
|
---|