14 lines
528 B
YAML
14 lines
528 B
YAML
#!/usr/bin/env ansible-playbook
|
|
# vim:ft=ansible:
|
|
- name: configure ansible user
|
|
block:
|
|
- name: create ansible user
|
|
user: name=ansible password_lock=yes
|
|
- name: configure ansible user home directory
|
|
file: path=/home/ansible owner=ansible group=ansible
|
|
- name: configure ansible user keys
|
|
authorized_key: user=ansible manage_dir=yes key={{ common_ansible_pubkey }}
|
|
- name: configure ansible user sudo
|
|
lineinfile: path=/etc/sudoers line="ansible ALL=(ALL:ALL) NOPASSWD:ALL"
|
|
become: yes
|