salt.modules.systemd

Provide the service module for systemd

Members

disable

salt.modules.systemd.disable(name)

Disable the named service to not start when the system boots

CLI Example:

salt '*' service.disable <service name>

disabled

salt.modules.systemd.disabled(name)

Return if the named service is disabled to start on boot

CLI Example:

salt '*' service.disabled <service name>

enable

salt.modules.systemd.enable(name)

Enable the named service to start when the system boots

CLI Example:

salt '*' service.enable <service name>

enabled

salt.modules.systemd.enabled(name)

Return if the named service is enabled to start on boot

CLI Example:

salt '*' service.enabled <service name>

get_all

salt.modules.systemd.get_all()

Return a list of all available services

CLI Example:

salt '*' service.get_all

get_disabled

salt.modules.systemd.get_disabled()

Return a list of all disabled services

CLI Example:

salt '*' service.get_disabled

get_enabled

salt.modules.systemd.get_enabled()

Return a list of all enabled services

CLI Example:

salt '*' service.get_enabled

reload

salt.modules.systemd.reload(name)

Reload the specified service with systemd

CLI Example:

salt '*' service.reload <service name>

restart

salt.modules.systemd.restart(name)

Restart the specified service with systemd

CLI Example:

salt '*' service.restart <service name>

start

salt.modules.systemd.start(name)

Start the specified service with systemd

CLI Example:

salt '*' service.start <service name>

status

salt.modules.systemd.status(name, sig=None)

Return the status for a service via systemd, returns the PID if the service is running or an empty string if the service is not running

CLI Example:

salt '*' service.status <service name>

stop

salt.modules.systemd.stop(name)

Stop the specified service with systemd

CLI Example:

salt '*' service.stop <service name>

Parent topic

Table Of Contents

Previous topic

salt.modules.status

Next topic

salt.modules.test