1CDIST-TYPE__PROCESS(7)               cdist              CDIST-TYPE__PROCESS(7)
2
3
4

NAME

6       cdist-type__process - Start or stop process
7

DESCRIPTION

9       This cdist type allows you to define the state of a process.
10

OPTIONAL PARAMETERS

12       state  Either "present" or "absent", defaults to "present"
13
14       name   Process name to match on when using pgrep -f -x.
15
16              This is useful, if the name starts with a "/", because the lead‐
17              ing slash is stripped away from the object id by cdist.
18
19       stop   Executable to use for stopping the process.
20
21       start  Executable to use for starting the process.
22

MESSAGES

24       started
25              The process was started.
26
27       stopped
28              The process was stopped.
29

EXAMPLES

31          # Start if not running
32          __process /usr/sbin/syslog-ng --state present
33
34          # Start if not running with a different binary
35          __process /usr/sbin/nginx --state present --start "/etc/rc.d/nginx start"
36
37          # Stop the process using kill (the type default) - DO NOT USE THIS
38          __process /usr/sbin/sshd --state absent
39
40          # Stop the process using /etc/rc.d/sshd stop - THIS ONE NOT AS WELL
41          __process /usr/sbin/sshd --state absent --stop "/etc/rc.d/sshd stop"
42
43          # Ensure cups is running, which runs with -C ...:
44          __process cups --start "/etc/rc.d/cups start" --state present \
45             --name "/usr/sbin/cupsd -C /etc/cups/cupsd.conf"
46
47          # Ensure rpc.statd is running (which usually runs with -L) using a regexp
48          __process rpcstatd --state present --start "/etc/init.d/statd start" \
49              --name "rpc.statd.*"
50

SEE ALSO

52       cdist-type__start_on_boot(7)
53

AUTHORS

55       Nico Schottelius <nico-cdist--@--schottelius.org>
56       Thomas Eckert <tom--@--it-eckert.de>
57
58

COPYING

60       Copyright (C) 2011-2012  Nico  Schottelius.  You  can  redistribute  it
61       and/or  modify  it under the terms of the GNU General Public License as
62       published by the Free Software Foundation, either version 3 of the  Li‐
63       cense, or (at your option) any later version.
64
66       ungleich GmbH 2020
67
68
69
70
716.9.6                            Apr 20, 2021           CDIST-TYPE__PROCESS(7)
Impressum