Documentation

group - Add or remove groups

Synopsis

Manage presence of groups on a host.

Requirements (on host that executes module)

  • groupadd
  • groupdel
  • groupmod

Options

parameter required default choices comments
gid
no
    Optional GID to set for the group.
    name
    yes
      Name of the group to manage.
      state
      no present
      • present
      • absent
      Whether the group should be present or not on the remote host.
      system
      no no
      • yes
      • no
      If yes, indicates that the group created is a system group.

      Examples

      # Example group command from Ansible Playbooks
      - group: name=somegroup state=present
      

      This is a Core Module

      For more information on what this means please read Core Modules

      For help in developing on modules, should you be so inclined, please read Community Information & Contributing, Helping Testing PRs and Developing Modules.