<?xml version="1.0" encoding="UTF-8"?>
<!--
! CCPL HEADER START
!
! This work is licensed under the Creative Commons
! Attribution-NonCommercial-NoDerivs 3.0 Unported License.
! To view a copy of this license, visit
! http://creativecommons.org/licenses/by-nc-nd/3.0/
! or send a letter to Creative Commons, 444 Castro Street,
! Suite 900, Mountain View, California, 94041, USA.
!
! You can also obtain a copy of the license at
! trunk/opendj3/legal-notices/CC-BY-NC-ND.txt.
! See the License for the specific language governing permissions
! and limitations under the License.
!
! If applicable, add the following below this CCPL HEADER, with the fields
! enclosed by brackets "[]" replaced with your own identifying information:
! Portions Copyright [yyyy] [name of copyright owner]
!
! CCPL HEADER END
!
! Copyright 2011-2012 ForgeRock AS
! Portions Copyright 2013 Jens Elkner
!
-->
<refentry xml:id='create-rc-script-1' xmlns='http://docbook.org/ns/docbook'
version='5.0'
xml:lang='en' xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance'
xsi:schemaLocation='http://docbook.org/ns/docbook http://docbook.org/xml/5.0/xsd/docbook.xsd'
xmlns:xlink='http://www.w3.org/1999/xlink'
xmlns:xi='http://www.w3.org/2001/XInclude'>
<xi:include href="common.xml" xpointer='xpointer(//info[@name="info"])'/>
<refmeta>
<refentrytitle><application>create-rc-script</application></refentrytitle>
<xi:include href="common.xml" xpointer='xpointer(//manvolnum[@name="v1m"])'/>
</refmeta>
<refnamediv>
<refname>create-rc-script</refname>
<refpurpose>script to manage OpenDJ as a service on UNIX</refpurpose>
</refnamediv>
<refsynopsisdiv>
<cmdsynopsis>
<command>create-rc-script</command>
<arg>-f <replaceable class="parameter">file</replaceable></arg>
<arg>-j <replaceable class="parameter">dir</replaceable></arg>
<arg>-J <replaceable class="parameter">args</replaceable></arg>
<arg>-u <replaceable class="parameter">username</replaceable></arg>
<xi:include href="common.xml"
xpointer='xpointer(//para[@name="s-general"]/*)'/>
</cmdsynopsis>
</refsynopsisdiv>
<refsection>
<title>Description</title>
<para>
Create an RC script that may be used to start, stop, and restart the directory
server on UNIX-based systems.
</para>
</refsection>
<refsection>
<title>Options</title>
<para>
The following options are supported.
</para>
<variablelist>
<varlistentry>
<term><option>-f, --outputFile</option> <replaceable
class="parameter">file</replaceable></term>
<listitem>
<para>
The path to the output file to create.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term><option>-j, --javaHome</option> <replaceable
class="parameter">dir</replaceable> </term>
<listitem>
<para>
The path to the Java installation that should be used to run the server.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term><option>-J, --javaArgs</option> <replaceable
class="parameter">args</replaceable></term>
<listitem>
<para>
A set of arguments that should be passed to the JVM when running the server.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term><option>-u, --userName</option> <replaceable
class="parameter">username</replaceable></term>
<listitem>
<para>
The name of the user account under which the server should run.
</para>
</listitem>
</varlistentry>
</variablelist>
</refsection>
<refsection>
<title>General Options</title>
<variablelist>
<xi:include href="common.xml"
xpointer='xpointer(//para[@name="l-general"]/*)'/>
</variablelist>
</refsection>
<refsection>
<title>Examples</title>
<informalexample>
<para>
The following example adds a script to start OpenDJ at boot time on a
Debian-based system, and then updates the runlevel system to use the script.
</para>
<literallayout><prompt
>$ </prompt><command>sudo create-rc-script -f /etc/init.d/opendj -u mark</command>
<prompt>$ </prompt><command>sudo update-rc.d opendj</command></literallayout>
</informalexample>
</refsection>
<xi:include href="common.xml" xpointer='xpointer(//refsection[@name="exit-0-gt0"])'/>
<xi:include href="common.xml" xpointer='xpointer(//refsection[@name="seeAlso"])'/>
</refentry>