Additional arguments provided on the command line that some init scripts accept.
aliases: args
daemonize
boolean
Choices:
no ←
yes
Have the module daemonize as the service itself might not do so properly.
This is useful with badly written init scripts or daemons, which commonly manifests as the task hanging as it is still holding the tty or the service dying when the task is over as the connection closes the session.
enabled
boolean
Choices:
no
yes
Whether the service should start on boot. At least one of state and enabled are required.
name
-
/ required
Name of the service.
aliases: service
pattern
-
A substring to look for as would be found in the output of the ps command as a stand-in for a status result.
If the string is found, the service will be assumed to be running.
This option is mainly for use with init scripts that don't support the 'status' option.
runlevels
-
The runlevels this script should be enabled/disabled from.
Use this to override the defaults set by the package or init script itself.
sleep
-
Default:
1
If the service is being restarted or reloaded then sleep this many seconds between the stop and start command. This helps to workaround badly behaving services.
state
-
Choices:
started
stopped
restarted
reloaded
started/stopped are idempotent actions that will not run commands unless necessary. Not all init scripts support restarted nor reloaded natively, so these will both trigger a stop and start as needed.
-name:make sure apache2 is startedsysvinit:name:apache2state:startedenabled:yes-name:make sure apache2 is started on runlevels 3 and 5sysvinit:name:apache2state:startedenabled:yesrunlevels:-3-5