start creating ansible tasks

This commit is contained in:
L3D 2021-12-15 01:03:37 +01:00
parent 838d25752c
commit 80d9b2aacb
Signed by: l3d
GPG key ID: CD08445BFF4313D1
3 changed files with 29 additions and 0 deletions

2
defaults/main.yml Normal file
View file

@ -0,0 +1,2 @@
---
win_base_init__ansible_password: ''

24
tasks/ansible_user.yml Normal file
View file

@ -0,0 +1,24 @@
---
- name: Create Windows group ansible
become: true
ansible.windows.win_group:
name: 'Ansible'
description: 'Group for Ansible Management'
state: present
- name: create ansible User
become: true
ansible.windows.win_user:
name: 'ansible'
state: present
password:
account_disabled: false
description: 'Account to run ansible commands at this WINDOWS host'
groups_action: 'add'
password_expired: false
password_never_expires: true
user_cannot_change_password: true
groups:
- 'Users'
- 'Administrator'
- 'Ansible'

3
tasks/main.yml Normal file
View file

@ -0,0 +1,3 @@
---
- name: create Ansible Windows Group and User
ansible.builtin.include_task: ansible_user.yml