win_user - Manages local Windows user accounts

Author:Paul Durivage

Synopsis

New in version 1.7.

Manages local Windows user accounts

Options

parameter required default choices comments
name yes
    Username of the user to manage
    password yes
      Password for the user (plain text)
      state no present
      • present
      • absent
      Whether to create or delete a user

      Examples


      # Ad-hoc example
      $ ansible -i hosts -m win_user -a "name=bob password=Password12345" all
      $ ansible -i hosts -m win_user -a "name=bob password=Password12345 state=absent" all
      
      # Playbook example
      ---
      - name: Add a user
        hosts: all
        gather_facts: false
        tasks:
          - name: Add User
            win_user:
              name: ansible
              password: "@ns1bl3"
      

      Table Of Contents

      Previous topic

      win_stat - returns information about a Windows file

      Next topic

      Detailed Guides