I create users with these tasks:
- name: ensure home directory
sudo: yes
file: path={{item.home}} state=directory
with_items: users
- name: create user {{item.name}}
sudo: yes
user: name={{item.name}} home={{item.home}} shell=/bin/bash group={{item.group}} groups={{item.groups}} password={{item.password}} state=present
with_items: users
but it seems that ~ / .bashrc per user is not created in their home directory.
Is there a way to create a default .bashrc base file?
thanks
source
share