59 lines
3.1 KiB
XML
59 lines
3.1 KiB
XML
<?xml version='1.0'?>
|
|
<!DOCTYPE service_bundle SYSTEM '/usr/share/lib/xml/dtd/service_bundle.dtd.1'>
|
|
<service_bundle type='manifest' name='export'>
|
|
<service name='@SMF_PREFIX@/@SMF_NAME@' type='service' version='0'>
|
|
<create_default_instance enabled='false' />
|
|
<single_instance />
|
|
<dependency name='fs' grouping='require_all' restart_on='none' type='service'>
|
|
<service_fmri value='svc:/system/filesystem/local' />
|
|
</dependency>
|
|
<dependency name='net' grouping='require_all' restart_on='none' type='service'>
|
|
<service_fmri value='svc:/network/loopback' />
|
|
</dependency>
|
|
<dependent name='elasticsearch' restart_on='none' grouping='optional_all'>
|
|
<service_fmri value='svc:/milestone/multi-user' />
|
|
</dependent>
|
|
<method_context working_directory='@ES_TMPDIR@'>
|
|
<method_credential user='@ES_USER@' group='@ES_GROUP@' />
|
|
<method_environment>
|
|
<envvar name='PATH' value='@PREFIX@/bin:@PREFIX@/sbin:/usr/bin:/usr/sbin' />
|
|
<envvar name='JAVA_HOME' value='@PKG_JAVA_HOME@' />
|
|
</method_environment>
|
|
</method_context>
|
|
<exec_method name='start' type='method' exec='@PKG_JAVA_HOME@/bin/java -Delasticsearch -Des.path.home=@PREFIX@ -Des.path.conf=@PKG_SYSCONFDIR@ -Des.pidfile=@ES_PIDDIR@/elasticsearch.pid -Des.index.store.type=%{store_type} %{java_opts} -Xms%{min_heap} -Xmx%{max_heap} -cp %{class_path} org.elasticsearch.bootstrap.Elasticsearch start' timeout_seconds='3600' />
|
|
<exec_method type='method' name='stop' exec=':kill' timeout_seconds='60' />
|
|
<exec_method type='method' name='refresh' exec=':kill -HUP' timeout_seconds='60' />
|
|
<property_group name='application' type='application'>
|
|
<propval name='min_heap' type='astring' value='256m' />
|
|
<propval name='max_heap' type='astring' value='1g' />
|
|
<propval name='store_type' type='astring' value='niofs' />
|
|
<propval name='class_path' type='astring' value='@ES_LIBDIR@/@DISTNAME@.jar:@ES_LIBDIR@/*' />
|
|
<property name='java_opts' type='astring'>
|
|
<astring_list>
|
|
<value_node value='-Dfile.encoding=UTF-8'/>
|
|
<value_node value='-Djava.awt.headless=true'/>
|
|
<value_node value='-XX:+DisableExplicitGC'/>
|
|
<value_node value='-XX:+HeapDumpOnOutOfMemoryError'/>
|
|
<value_node value='-XX:+UseCMSInitiatingOccupancyOnly'/>
|
|
<value_node value='-XX:+UseConcMarkSweepGC'/>
|
|
<value_node value='-XX:+UseParNewGC'/>
|
|
<value_node value='-XX:CMSInitiatingOccupancyFraction=75'/>
|
|
<value_node value='-Xss256k'/>
|
|
</astring_list>
|
|
</property>
|
|
</property_group>
|
|
<property_group name='startd' type='framework'>
|
|
<propval name='duration' type='astring' value='child' />
|
|
</property_group>
|
|
<template>
|
|
<common_name>
|
|
<loctext xml:lang='C'>ElasticSearch: A Distributed RESTful Search Engine</loctext>
|
|
</common_name>
|
|
<documentation>
|
|
<doc_link name='ElasticSearch Home Page' uri='http://www.elasticsearch.org/' />
|
|
<doc_link name='ElasticSearch Guides' uri='http://www.elasticsearch.org/guide/' />
|
|
</documentation>
|
|
</template>
|
|
</service>
|
|
</service_bundle>
|