1<?xml version="1.0"?>
2<!DOCTYPE service_bundle SYSTEM "/usr/share/lib/xml/dtd/service_bundle.dtd.1">
3<!--
4    CDDL HEADER START
5
6    The contents of this file are subject to the terms of the
7    Common Development and Distribution License (the "License").
8    You may not use this file except in compliance with the License.
9
10    You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
11    or http://www.opensolaris.org/os/licensing.
12    See the License for the specific language governing permissions
13    and limitations under the License.
14
15    When distributing Covered Code, include this CDDL HEADER in each
16    file and include the License file at usr/src/OPENSOLARIS.LICENSE.
17    If applicable, add the following below this CDDL HEADER, with the
18    fields enclosed by brackets "[]" replaced with your own identifying
19    information: Portions Copyright [yyyy] [name of copyright owner]
20
21    CDDL HEADER END
22
23    Copyright 2009 Sun Microsystems, Inc.  All rights reserved.
24    Use is subject to license terms.
25
26    Copyright 2016 Hans Rosenfeld <rosenfeld@grumpf.hope-2000.org>
27
28    NOTE:  This service manifest is not editable; its contents will
29    be overwritten by package or patch operations, including
30    operating system upgrade.  Make customizations in a different
31    file.
32-->
33
34<service_bundle type='manifest' name='SUNWsndmr:sendmail'>
35
36<service
37	name='network/smtp'
38	type='service'
39	version='1'>
40
41	<single_instance />
42
43	<dependency
44	    name='fs-local'
45	    grouping='require_all'
46	    restart_on='none'
47	    type='service'>
48		<service_fmri value='svc:/system/filesystem/local' />
49	</dependency>
50
51	<dependency
52	    name='network-service'
53	    grouping='require_all'
54	    restart_on='none'
55	    type='service'>
56		<service_fmri value='svc:/network/service' />
57	</dependency>
58
59	<dependency
60	    name='name-services'
61	    grouping='require_all'
62	    restart_on='refresh'
63	    type='service'>
64		<service_fmri value='svc:/milestone/name-services' />
65	</dependency>
66
67	<dependency
68	    name='identity'
69	    grouping='optional_all'
70	    restart_on='refresh'
71	    type='service'>
72		<service_fmri value='svc:/system/identity:domain' />
73	</dependency>
74
75	<dependency
76	    name='system-log'
77	    grouping='optional_all'
78	    restart_on='none'
79	    type='service'>
80		<service_fmri value='svc:/system/system-log' />
81	</dependency>
82
83	<property_group name='firewall_context' type='com.sun,fw_definition'>
84		<propval name='name' type='astring' value='smtp' />
85	</property_group>
86
87	<property_group name='firewall_config' type='com.sun,fw_configuration'>
88		<propval name='policy' type='astring' value='use_global' />
89		<propval name='block_policy' type='astring'
90			value='use_global' />
91		<propval name='apply_to' type='astring' value='' />
92		<propval name='apply_to_6' type='astring' value='' />
93		<propval name='exceptions' type='astring' value='' />
94		<propval name='exceptions_6' type='astring' value='' />
95		<propval name='target' type='astring' value='' />
96		<propval name='target_6' type='astring' value='' />
97		<propval name='value_authorization' type='astring'
98			value='solaris.smf.value.firewall.config' />
99	</property_group>
100
101	<instance name='sendmail' enabled='false'>
102
103		<dependency
104		    name='config-file'
105		    grouping='require_all'
106		    restart_on='refresh'
107		    type='path'>
108			<service_fmri
109			    value='file://localhost/etc/mail/sendmail.cf' />
110		</dependency>
111
112		<dependency
113		    name='nsswitch'
114		    grouping='require_all'
115		    restart_on='refresh'
116		    type='path'>
117			<service_fmri
118			    value='file://localhost/etc/nsswitch.conf' />
119		</dependency>
120
121		<!--
122		If autofs is enabled, wait for it to get users' home
123		directories.
124		-->
125		<dependency
126		    name='autofs'
127		    grouping='optional_all'
128		    restart_on='none'
129		    type='service'>
130			<service_fmri value='svc:/system/filesystem/autofs' />
131		</dependency>
132
133		<dependent
134			name='smtp-sendmail_multi-user'
135			grouping='optional_all'
136			restart_on='none'>
137				<service_fmri
138				    value='svc:/milestone/multi-user' />
139		</dependent>
140
141		<!--
142		Sendmail is hard-coded to sleep for 60 seconds if it cannot
143		determine the FQHN, so the timeout for start must be longer
144		than that.  For details, see
145		http://www.sendmail.org/vendor/sun/differences.html#3.2
146		-->
147
148		<exec_method
149			type='method'
150			name='start'
151			exec='/lib/svc/method/smtp-sendmail start'
152			timeout_seconds='120' />
153
154		<exec_method
155			type='method'
156			name='stop'
157			exec='/lib/svc/method/smtp-sendmail stop %{restarter/contract}'
158			timeout_seconds='60' />
159
160		<exec_method
161			type='method'
162			name='refresh'
163			exec='/lib/svc/method/smtp-sendmail refresh'
164			timeout_seconds='60' />
165
166		<property_group name='startd' type='framework'>
167			<propval name='ignore_error' type='astring'
168			    value='core,signal' />
169		</property_group>
170
171		<property_group name='general' type='framework'>
172			<propval name='action_authorization' type='astring'
173				value='solaris.smf.manage.sendmail' />
174		</property_group>
175
176		<property_group name='config' type='application'>
177			<propval name='include_info'
178				type='boolean' value='false' />
179			<propval name='local_only'
180				type='boolean' value='true' />
181			<propval name='path_to_sendmail_mc'
182				type='astring' value='' />
183			<propval name='value_authorization' type='astring'
184				value='solaris.smf.value.sendmail' />
185		</property_group>
186
187		<template>
188			<common_name>
189				<loctext xml:lang='C'>
190				sendmail SMTP mail transfer agent
191				</loctext>
192			</common_name>
193			<documentation>
194				<manpage title='sendmail' section='8'
195				    manpath='/usr/share/man' />
196			</documentation>
197		</template>
198
199	</instance>
200
201	<stability value='Unstable' />
202
203</service>
204
205</service_bundle>
206