systemd.exec.xml revision 71b1c27a406271b71f64487ae70b58f44a4a37f0
45d7a8bb6c0e0caa4dd2a1cf1108b7ba2c0ebac4Lennart Poettering<?xml version='1.0'?> <!--*- Mode: nxml; nxml-child-indent: 2; indent-tabs-mode: nil -*-->
caa94887002de8596c69f578dbdb684dfb368240Lennart Poettering<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN"
12b42c76672a66c2d4ea7212c14f8f1b5a62b78dTom Gundersen "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd">
caa94887002de8596c69f578dbdb684dfb368240Lennart Poettering This file is part of systemd.
caa94887002de8596c69f578dbdb684dfb368240Lennart Poettering Copyright 2010 Lennart Poettering
caa94887002de8596c69f578dbdb684dfb368240Lennart Poettering systemd is free software; you can redistribute it and/or modify it
5430f7f2bc7330f3088b894166bf3524a067e3d8Lennart Poettering under the terms of the GNU Lesser General Public License as published by
5430f7f2bc7330f3088b894166bf3524a067e3d8Lennart Poettering the Free Software Foundation; either version 2.1 of the License, or
caa94887002de8596c69f578dbdb684dfb368240Lennart Poettering (at your option) any later version.
caa94887002de8596c69f578dbdb684dfb368240Lennart Poettering systemd is distributed in the hope that it will be useful, but
caa94887002de8596c69f578dbdb684dfb368240Lennart Poettering WITHOUT ANY WARRANTY; without even the implied warranty of
caa94887002de8596c69f578dbdb684dfb368240Lennart Poettering MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
5430f7f2bc7330f3088b894166bf3524a067e3d8Lennart Poettering Lesser General Public License for more details.
5430f7f2bc7330f3088b894166bf3524a067e3d8Lennart Poettering You should have received a copy of the GNU Lesser General Public License
caa94887002de8596c69f578dbdb684dfb368240Lennart Poettering along with systemd; If not, see <http://www.gnu.org/licenses/>.
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <productname>systemd</productname>
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <email>lennart@poettering.net</email>
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <refentrytitle>systemd.exec</refentrytitle>
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <refpurpose>Execution environment configuration</refpurpose>
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <refsynopsisdiv>
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <para><filename><replaceable>service</replaceable>.service</filename>,
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <filename><replaceable>socket</replaceable>.socket</filename>,
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <filename><replaceable>mount</replaceable>.mount</filename>,
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <filename><replaceable>swap</replaceable>.swap</filename></para>
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek </refsynopsisdiv>
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <para>Unit configuration files for services, sockets, mount
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek points, and swap devices share a subset of configuration options
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek which define the execution environment of spawned
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek processes.</para>
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <para>This man page lists the configuration options shared by
780fe62ecab08850cefd136b95f38c15cb31c0ecCharles Duffy these four unit types. See
780fe62ecab08850cefd136b95f38c15cb31c0ecCharles Duffy <citerefentry><refentrytitle>systemd.unit</refentrytitle><manvolnum>5</manvolnum></citerefentry>
45d7a8bb6c0e0caa4dd2a1cf1108b7ba2c0ebac4Lennart Poettering for the common options of all unit configuration files, and
45d7a8bb6c0e0caa4dd2a1cf1108b7ba2c0ebac4Lennart Poettering <citerefentry><refentrytitle>systemd.service</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
45d7a8bb6c0e0caa4dd2a1cf1108b7ba2c0ebac4Lennart Poettering <citerefentry><refentrytitle>systemd.socket</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
45d7a8bb6c0e0caa4dd2a1cf1108b7ba2c0ebac4Lennart Poettering <citerefentry><refentrytitle>systemd.swap</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <citerefentry><refentrytitle>systemd.mount</refentrytitle><manvolnum>5</manvolnum></citerefentry>
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek for more information on the specific unit configuration files. The
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek execution specific configuration options are configured in the
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek [Service], [Socket], [Mount], or [Swap] sections, depending on the
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek unit type.</para>
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <variablelist class='unit-directives'>
b0f5a5105ba3e57c20528ee2c292cd1f7300da8fUmut Tezduyar Lindskog <term><varname>WorkingDirectory=</varname></term>
b0f5a5105ba3e57c20528ee2c292cd1f7300da8fUmut Tezduyar Lindskog <listitem><para>Takes an absolute directory path, or the
b0f5a5105ba3e57c20528ee2c292cd1f7300da8fUmut Tezduyar Lindskog special value <literal>~</literal>. Sets the working directory
b0f5a5105ba3e57c20528ee2c292cd1f7300da8fUmut Tezduyar Lindskog for executed processes. If set to <literal>~</literal> the
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek home directory of the user specified in
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <varname>User=</varname> is used. If not set, defaults to the
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek root directory when systemd is running as a system instance
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek and the respective user's home directory if run as user. If
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek the setting is prefixed with the <literal>-</literal>
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek character, a missing working directory is not considered
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <term><varname>RootDirectory=</varname></term>
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <listitem><para>Takes an absolute directory path. Sets the
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek root directory for executed processes, with the <citerefentry
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek project='man-pages'><refentrytitle>chroot</refentrytitle><manvolnum>2</manvolnum></citerefentry>
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek system call. If this is used, it must be ensured that the
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek process binary and all its auxiliary files are available in
45d7a8bb6c0e0caa4dd2a1cf1108b7ba2c0ebac4Lennart Poettering the <function>chroot()</function> jail.</para></listitem>
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <term><varname>User=</varname></term>
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <term><varname>Group=</varname></term>
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <listitem><para>Sets the Unix user or group that the processes
45d7a8bb6c0e0caa4dd2a1cf1108b7ba2c0ebac4Lennart Poettering are executed as, respectively. Takes a single user or group
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek name or ID as argument. If no group is set, the default group
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <term><varname>SupplementaryGroups=</varname></term>
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <listitem><para>Sets the supplementary Unix groups the
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek processes are executed as. This takes a space-separated list
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek of group names or IDs. This option may be specified more than
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek once in which case all listed groups are set as supplementary
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek groups. When the empty string is assigned the list of
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek supplementary groups is reset, and all assignments prior to
45d7a8bb6c0e0caa4dd2a1cf1108b7ba2c0ebac4Lennart Poettering this one will have no effect. In any way, this option does not
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek override, but extends the list of supplementary groups
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek configured in the system group database for the
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <listitem><para>Sets the default nice level (scheduling
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek priority) for executed processes. Takes an integer between -20
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek (highest priority) and 19 (lowest priority). See
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <citerefentry><refentrytitle>setpriority</refentrytitle><manvolnum>2</manvolnum></citerefentry>
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <term><varname>OOMScoreAdjust=</varname></term>
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <listitem><para>Sets the adjustment level for the
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek Out-Of-Memory killer for executed processes. Takes an integer
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek between -1000 (to disable OOM killing for this process) and
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek 1000 (to make killing of this process under memory pressure
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek very likely). See <ulink
a2c9f63136775b128bdb9fb3e1b57f5ad977d5cbCharles Duffy url="https://www.kernel.org/doc/Documentation/filesystems/proc.txt">proc.txt</ulink>
a2c9f63136775b128bdb9fb3e1b57f5ad977d5cbCharles Duffy </varlistentry>
a2c9f63136775b128bdb9fb3e1b57f5ad977d5cbCharles Duffy <varlistentry>
a2c9f63136775b128bdb9fb3e1b57f5ad977d5cbCharles Duffy <term><varname>IOSchedulingClass=</varname></term>
a2c9f63136775b128bdb9fb3e1b57f5ad977d5cbCharles Duffy <listitem><para>Sets the IO scheduling class for executed
a2c9f63136775b128bdb9fb3e1b57f5ad977d5cbCharles Duffy processes. Takes an integer between 0 and 3 or one of the
45d7a8bb6c0e0caa4dd2a1cf1108b7ba2c0ebac4Lennart Poettering strings <option>none</option>, <option>realtime</option>,
45d7a8bb6c0e0caa4dd2a1cf1108b7ba2c0ebac4Lennart Poettering <option>best-effort</option> or <option>idle</option>. See
45d7a8bb6c0e0caa4dd2a1cf1108b7ba2c0ebac4Lennart Poettering <citerefentry><refentrytitle>ioprio_set</refentrytitle><manvolnum>2</manvolnum></citerefentry>
45d7a8bb6c0e0caa4dd2a1cf1108b7ba2c0ebac4Lennart Poettering </varlistentry>
6d3eefd28e653c42bc4a6e0e58dfd9581b5c6e0aLennart Poettering <varlistentry>
6d3eefd28e653c42bc4a6e0e58dfd9581b5c6e0aLennart Poettering <term><varname>IOSchedulingPriority=</varname></term>
45d7a8bb6c0e0caa4dd2a1cf1108b7ba2c0ebac4Lennart Poettering <listitem><para>Sets the IO scheduling priority for executed
41ba8b6e69ad79b6c8e603ac970720665c88a363Lennart Poettering processes. Takes an integer between 0 (highest priority) and 7
41ba8b6e69ad79b6c8e603ac970720665c88a363Lennart Poettering (lowest priority). The available priorities depend on the
41ba8b6e69ad79b6c8e603ac970720665c88a363Lennart Poettering selected IO scheduling class (see above). See
41ba8b6e69ad79b6c8e603ac970720665c88a363Lennart Poettering <citerefentry><refentrytitle>ioprio_set</refentrytitle><manvolnum>2</manvolnum></citerefentry>
6d3eefd28e653c42bc4a6e0e58dfd9581b5c6e0aLennart Poettering </varlistentry>
41ba8b6e69ad79b6c8e603ac970720665c88a363Lennart Poettering <varlistentry>
41ba8b6e69ad79b6c8e603ac970720665c88a363Lennart Poettering <term><varname>CPUSchedulingPolicy=</varname></term>
3cb5beea0c484011fffbd50ae0aaaf71cc699eefLennart Poettering <listitem><para>Sets the CPU scheduling policy for executed
3cb5beea0c484011fffbd50ae0aaaf71cc699eefLennart Poettering processes. Takes one of
6d3eefd28e653c42bc4a6e0e58dfd9581b5c6e0aLennart Poettering <citerefentry><refentrytitle>sched_setscheduler</refentrytitle><manvolnum>2</manvolnum></citerefentry>
6d3eefd28e653c42bc4a6e0e58dfd9581b5c6e0aLennart Poettering </varlistentry>
3cb5beea0c484011fffbd50ae0aaaf71cc699eefLennart Poettering <varlistentry>
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <term><varname>CPUSchedulingPriority=</varname></term>
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <listitem><para>Sets the CPU scheduling priority for executed
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek processes. The available priority range depends on the
6d3eefd28e653c42bc4a6e0e58dfd9581b5c6e0aLennart Poettering selected CPU scheduling policy (see above). For real-time
6d3eefd28e653c42bc4a6e0e58dfd9581b5c6e0aLennart Poettering scheduling policies an integer between 1 (lowest priority) and
6d3eefd28e653c42bc4a6e0e58dfd9581b5c6e0aLennart Poettering 99 (highest priority) can be used. See
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <citerefentry><refentrytitle>sched_setscheduler</refentrytitle><manvolnum>2</manvolnum></citerefentry>
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <term><varname>CPUSchedulingResetOnFork=</varname></term>
6d3eefd28e653c42bc4a6e0e58dfd9581b5c6e0aLennart Poettering <listitem><para>Takes a boolean argument. If true, elevated
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek CPU scheduling priorities and policies will be reset when the
6d3eefd28e653c42bc4a6e0e58dfd9581b5c6e0aLennart Poettering executed processes fork, and can hence not leak into child
6d3eefd28e653c42bc4a6e0e58dfd9581b5c6e0aLennart Poettering processes. See
6d3eefd28e653c42bc4a6e0e58dfd9581b5c6e0aLennart Poettering <citerefentry><refentrytitle>sched_setscheduler</refentrytitle><manvolnum>2</manvolnum></citerefentry>
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek for details. Defaults to false.</para></listitem>
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <term><varname>CPUAffinity=</varname></term>
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <listitem><para>Controls the CPU affinity of the executed
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek processes. Takes a list of CPU indices or ranges separated by
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek either whitespace or commas. CPU ranges are specified by the
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek lower and upper CPU indices separated by a dash.
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek This option may be specified more than once in which case the
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek specified CPU affinity masks are merged. If the empty string
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek is assigned, the mask is reset, all assignments prior to this
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek will have no effect. See
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <citerefentry><refentrytitle>sched_setaffinity</refentrytitle><manvolnum>2</manvolnum></citerefentry>
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <term><varname>UMask=</varname></term>
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <listitem><para>Controls the file mode creation mask. Takes an
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek access mode in octal notation. See
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <citerefentry><refentrytitle>umask</refentrytitle><manvolnum>2</manvolnum></citerefentry>
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek for details. Defaults to 0022.</para></listitem>
6d3eefd28e653c42bc4a6e0e58dfd9581b5c6e0aLennart Poettering <varlistentry>
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <term><varname>Environment=</varname></term>
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <listitem><para>Sets environment variables for executed
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek processes. Takes a space-separated list of variable
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek assignments. This option may be specified more than once in
6d3eefd28e653c42bc4a6e0e58dfd9581b5c6e0aLennart Poettering which case all listed variables will be set. If the same
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek variable is set twice, the later setting will override the
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek earlier setting. If the empty string is assigned to this
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek option, the list of environment variables is reset, all prior
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek assignments have no effect. Variable expansion is not
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek performed inside the strings, however, specifier expansion is
6d3eefd28e653c42bc4a6e0e58dfd9581b5c6e0aLennart Poettering possible. The $ character has no special meaning. If you need
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek to assign a value containing spaces to a variable, use double
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek quotes (") for the assignment.</para>
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <programlisting>Environment="VAR1=word1 word2" VAR2=word3 "VAR3=$word 5 6"</programlisting>
6d3eefd28e653c42bc4a6e0e58dfd9581b5c6e0aLennart Poettering gives three variables <literal>VAR1</literal>,
6d3eefd28e653c42bc4a6e0e58dfd9581b5c6e0aLennart Poettering <literal>VAR2</literal>, <literal>VAR3</literal>
6d3eefd28e653c42bc4a6e0e58dfd9581b5c6e0aLennart Poettering with the values <literal>word1 word2</literal>,
6d3eefd28e653c42bc4a6e0e58dfd9581b5c6e0aLennart Poettering <literal>word3</literal>, <literal>$word 5 6</literal>.
6d3eefd28e653c42bc4a6e0e58dfd9581b5c6e0aLennart Poettering <citerefentry project='man-pages'><refentrytitle>environ</refentrytitle><manvolnum>7</manvolnum></citerefentry>
6d3eefd28e653c42bc4a6e0e58dfd9581b5c6e0aLennart Poettering for details about environment variables.</para></listitem>
6d3eefd28e653c42bc4a6e0e58dfd9581b5c6e0aLennart Poettering </varlistentry>
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <term><varname>EnvironmentFile=</varname></term>
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <listitem><para>Similar to <varname>Environment=</varname> but
6d3eefd28e653c42bc4a6e0e58dfd9581b5c6e0aLennart Poettering reads the environment variables from a text file. The text
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek file should contain new-line-separated variable assignments.
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek Empty lines, lines without an <literal>=</literal> separator,
6d3eefd28e653c42bc4a6e0e58dfd9581b5c6e0aLennart Poettering or lines starting with ; or # will be ignored,
6d3eefd28e653c42bc4a6e0e58dfd9581b5c6e0aLennart Poettering which may be used for commenting. A line ending with a
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek backslash will be concatenated with the following one,
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek allowing multiline variable definitions. The parser strips
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek leading and trailing whitespace from the values of
6d3eefd28e653c42bc4a6e0e58dfd9581b5c6e0aLennart Poettering assignments, unless you use double quotes (").</para>
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <para>The argument passed should be an absolute filename or
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek wildcard expression, optionally prefixed with
6d3eefd28e653c42bc4a6e0e58dfd9581b5c6e0aLennart Poettering <literal>-</literal>, which indicates that if the file does
6d3eefd28e653c42bc4a6e0e58dfd9581b5c6e0aLennart Poettering not exist, it will not be read and no error or warning message
6d3eefd28e653c42bc4a6e0e58dfd9581b5c6e0aLennart Poettering is logged. This option may be specified more than once in
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek which case all specified files are read. If the empty string
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek is assigned to this option, the list of file to read is reset,
7fcfb7ee2f0c2562c0e102915cacbc3ec2c4b8f8Lennart Poettering all prior assignments have no effect.</para>
7fcfb7ee2f0c2562c0e102915cacbc3ec2c4b8f8Lennart Poettering <para>The files listed with this directive will be read
7fcfb7ee2f0c2562c0e102915cacbc3ec2c4b8f8Lennart Poettering shortly before the process is executed (more specifically,
6d3eefd28e653c42bc4a6e0e58dfd9581b5c6e0aLennart Poettering after all processes from a previous unit state terminated.
6d3eefd28e653c42bc4a6e0e58dfd9581b5c6e0aLennart Poettering This means you can generate these files in one unit state, and
6d3eefd28e653c42bc4a6e0e58dfd9581b5c6e0aLennart Poettering read it with this option in the next).</para>
7fcfb7ee2f0c2562c0e102915cacbc3ec2c4b8f8Lennart Poettering <para>Settings from these
7fcfb7ee2f0c2562c0e102915cacbc3ec2c4b8f8Lennart Poettering files override settings made with
6d3eefd28e653c42bc4a6e0e58dfd9581b5c6e0aLennart Poettering <varname>Environment=</varname>. If the same variable is set
7fcfb7ee2f0c2562c0e102915cacbc3ec2c4b8f8Lennart Poettering twice from these files, the files will be read in the order
7fcfb7ee2f0c2562c0e102915cacbc3ec2c4b8f8Lennart Poettering they are specified and the later setting will override the
6d3eefd28e653c42bc4a6e0e58dfd9581b5c6e0aLennart Poettering </varlistentry>
6d3eefd28e653c42bc4a6e0e58dfd9581b5c6e0aLennart Poettering <varlistentry>
7fcfb7ee2f0c2562c0e102915cacbc3ec2c4b8f8Lennart Poettering <term><varname>StandardInput=</varname></term>
7fcfb7ee2f0c2562c0e102915cacbc3ec2c4b8f8Lennart Poettering <listitem><para>Controls where file descriptor 0 (STDIN) of
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek the executed processes is connected to. Takes one of
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <para>If <option>null</option> is selected, standard input
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek will be connected to <filename>/dev/null</filename>, i.e. all
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek read attempts by the process will result in immediate
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <para>If <option>tty</option> is selected, standard input is
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek connected to a TTY (as configured by
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek <varname>TTYPath=</varname>, see below) and the executed
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek process becomes the controlling process of the terminal. If
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek the terminal is already being controlled by another process,
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek the executed process waits until the current controlling
798d3a524ea57aaf40cb53858aaa45ec702f012dZbigniew Jędrzejewski-Szmek process releases the terminal.</para>
caa94887002de8596c69f578dbdb684dfb368240Lennart Poettering <para><option>tty-force</option> is similar to
caa94887002de8596c69f578dbdb684dfb368240Lennart Poettering <option>tty</option>, but the executed process is forcefully
<citerefentry project='freebsd'><refentrytitle>inetd</refentrytitle><manvolnum>8</manvolnum></citerefentry>
<citerefentry project='man-pages'><refentrytitle>syslog</refentrytitle><manvolnum>3</manvolnum></citerefentry>
<citerefentry project='man-pages'><refentrytitle>dmesg</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
<citerefentry><refentrytitle>systemd-system.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
<citerefentry><refentrytitle>systemd-system.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
<citerefentry project='man-pages'><refentrytitle>syslog</refentrytitle><manvolnum>3</manvolnum></citerefentry>
<citerefentry project='man-pages'><refentrytitle>syslog</refentrytitle><manvolnum>3</manvolnum></citerefentry>
<citerefentry project='man-pages'><refentrytitle>pam</refentrytitle><manvolnum>8</manvolnum></citerefentry>
<citerefentry project='man-pages'><refentrytitle>capabilities</refentrytitle><manvolnum>7</manvolnum></citerefentry>
<citerefentry project='mankier'><refentrytitle>cap_from_name</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
<citerefentry project='man-pages'><refentrytitle>capabilities</refentrytitle><manvolnum>7</manvolnum></citerefentry>
<citerefentry project='man-pages'><refentrytitle>capabilities</refentrytitle><manvolnum>7</manvolnum></citerefentry>
<citerefentry project='mankier'><refentrytitle>cap_from_text</refentrytitle><manvolnum>3</manvolnum></citerefentry>.
<citerefentry><refentrytitle>systemd.resource-control</refentrytitle><manvolnum>5</manvolnum></citerefentry>
<citerefentry project='man-pages'><refentrytitle>mount</refentrytitle><manvolnum>2</manvolnum></citerefentry>
replacements. This setting is unset by default, i.e. no
project='die-net'><refentrytitle>login</refentrytitle><manvolnum>1</manvolnum></citerefentry>-compatible
<citerefentry project='die-net'><refentrytitle>setexeccon</refentrytitle><manvolnum>3</manvolnum></citerefentry>
option is set to the empty list, i.e. no architecture system
<citerefentry project='man-pages'><refentrytitle>socket</refentrytitle><manvolnum>2</manvolnum></citerefentry>
<citerefentry project='man-pages'><refentrytitle>uname</refentrytitle><manvolnum>2</manvolnum></citerefentry>
<citerefentry><refentrytitle>tmpfiles.d</refentrytitle><manvolnum>5</manvolnum></citerefentry>.</para></listitem>
<filename>/usr/local/sbin</filename>:<filename>/usr/local/bin</filename>:<filename>/usr/sbin</filename>:<filename>/usr/bin</filename>:<filename>/sbin</filename>:<filename>/bin</filename>.
<citerefentry project='man-pages'><refentrytitle>locale.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>
<citerefentry><refentrytitle>kernel-command-line</refentrytitle><manvolnum>7</manvolnum></citerefentry>).
<citerefentry project='die-net'><refentrytitle>passwd</refentrytitle><manvolnum>5</manvolnum></citerefentry>.
<citerefentry project='man-pages'><refentrytitle>termcap</refentrytitle><manvolnum>5</manvolnum></citerefentry>.
<citerefentry><refentrytitle>systemd-system.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>)
cf. <citerefentry project='man-pages'><refentrytitle>pam_env</refentrytitle><manvolnum>8</manvolnum></citerefentry>.</para>
<citerefentry><refentrytitle>systemd.service</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
<citerefentry><refentrytitle>systemd.resource-control</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
<citerefentry><refentrytitle>systemd.directives</refentrytitle><manvolnum>7</manvolnum></citerefentry>,