Compare commits

...

2 commits

Author SHA1 Message Date
L3D
630130a84d
no admin 2021-12-20 18:21:39 +01:00
L3D
9381356e5d
create OBS user 2021-12-20 18:20:40 +01:00
4 changed files with 10 additions and 3 deletions

View file

@ -4,3 +4,9 @@
WINDOWS Ansible role to create a little base Setup for my Ansible Managed Windows 10 Enterprise Hosts
## Please not, this is my first windows role and highly experimental!
Requirements
----------------
+ **Pass or gopass** is required to store passwords.
+ See [ansible docs](https://docs.ansible.com/ansible/latest/collections/community/general/passwordstore_lookup.html)
+ Have a password store setup. Either create a symlink from pass to gopass or use pass nativly.

View file

@ -1,2 +1,2 @@
---
win_base_init__ansible_password: ''
win_base_init__pass_prefix: 'ansible/windows'

View file

@ -11,7 +11,7 @@
ansible.windows.win_user:
name: 'ansible'
state: present
password:
password: "{{ lookup('community.general.passwordstore', win_base_init__pass_prefix + '/' + inventory_hostname + '/password create=true length=16 nosymbols=true')}}"
account_disabled: false
description: 'Account to run ansible commands at this WINDOWS host'
groups_action: 'add'
@ -20,5 +20,4 @@
user_cannot_change_password: true
groups:
- 'Users'
- 'Administrator'
- 'Ansible'

View file

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