systemd

Collection: builtin

Full Name: parallax.builtin.systemd

Aliases: ansible.builtin.systemd, systemd

Synopsis

Manage systemd

Parameters

NameTypeRequiredDefaultDescription
namestringyesName of the systemd service unit
statestringstartedService state Choices: reloaded, restarted, started, stopped
enabledboolWhether the service should start on boot
daemon_reloadboolfalseRun daemon-reload before any action
daemon_reexecboolfalseRun daemon-reexec command before any action
scopestringsystemService scope Choices: system, user, global
forceboolfalseForce stop a service by sending SIGKILL
maskedboolWhether the unit should be masked
no_blockboolfalseDo not synchronously wait for operation to finish
userstringRun systemctl as this user (for user services)
servicestringalias for the name parameter

Example

- name: Example systemd task
  systemd:
    name: <your_name>