.Dd 1 May, 2009 .Dt launchd.plist 5 .Os Darwin .Sh NAME .Nm launchd.plist .Nd System wide and per-user daemon/agent configuration files .Sh DESCRIPTION This document details the parameters that can be given to an XML property list that can be loaded into .Nm launchd with .Nm launchctl . .Sh EXPECTATIONS Daemons or agents managed by .Nm launchd are expected to behave certain ways. .Pp A daemon or agent launched by .Nm launchd MUST NOT do the following in the process directly launched by .Nm launchd : .Pp .Bl -bullet -offset indent -compact .It Call .Xr daemon 3 . .It Do the moral equivalent of .Xr daemon 3 by calling .Xr fork 2 and have the parent process .Xr exit 3 or .Xr _exit 2 . .El .Pp A daemon or agent launched by .Nm launchd SHOULD NOT do the following as a part of their startup initialization: .Pp .Bl -bullet -offset indent -compact .It Setup the user ID or group ID. .It Setup the working directory. .It .Xr chroot 2 .It .Xr setsid 2 .It Close "stray" file descriptors. .It Change .Xr stdio 3 to /dev/null. .It Setup resource limits with .Xr setrusage 2 . .It Setup priority with .Xr setpriority 2 . .It Ignore the SIGTERM signal. .El .Pp A daemon or agent launched by .Nm launchd SHOULD: .Pp .Bl -bullet -offset indent -compact .It Launch on demand given criteria specified in the XML property list. More information can be found later in this man page. .It Catch the SIGTERM signal. .El .Sh XML PROPERTY LIST KEYS The following keys can be used to describe the configuration details of your daemon or agent. Property lists are Apple's standard configuration file format. Please see .Xr plist 5 for more information. Please note: property list files are expected to have their name end in ".plist". Also please note that it is the expected convention for launchd property list files to be named