roles/bootstrap/tasks/main.yml

Sun, 14 Jul 2019 03:28:13 -0500

author
Meredith Howard <mhoward@roomag.org>
date
Sun, 14 Jul 2019 03:28:13 -0500
changeset 91
a6f157cdf20e
parent 88
3dbfd253c775
permissions
-rw-r--r--

simplify package installs

---
- name: "Ansible control user"
  user:
    name: ansible
    comment: "Ansible Controller"
    home: /var/lib/ansible
    createhome: true
    append: true
    system: true
    state: present

- name: "Ansible pubkeys"
  authorized_key:
    manage_dir: true
    user: ansible
    key: "{{ item }}"
  with_file:
    - 'public_keys/ansible'

- name: "Ansible sudo"
  lineinfile:
    dest: /etc/sudoers
    state: present
    regexp: '^ansible'
    line: 'ansible ALL=(ALL) NOPASSWD: ALL'
    validate: 'visudo -cf "%s"'

mercurial