Add ansible playbook
This commit is contained in:
parent
d13417911c
commit
12681cca94
3 changed files with 27 additions and 0 deletions
|
@ -0,0 +1,23 @@
|
|||
- hosts: localhost
|
||||
vars_files:
|
||||
- ../map.yml
|
||||
tasks:
|
||||
- name: Install ansible packages
|
||||
package:
|
||||
name:
|
||||
- ansible
|
||||
state: present
|
||||
- name: Populate ansible config
|
||||
template:
|
||||
src: files/ansible_config
|
||||
dest: /etc/ansible/ansible.cfg
|
||||
owner: root
|
||||
group: root
|
||||
mode: '0644'
|
||||
- name: Ansible log directory
|
||||
file:
|
||||
state: directory
|
||||
path: /var/log/ansible
|
||||
owner: root
|
||||
group: root
|
||||
mode: '0700'
|
3
system/files/ansible_config
Normal file
3
system/files/ansible_config
Normal file
|
@ -0,0 +1,3 @@
|
|||
[defaults]
|
||||
inventory=/srv/ansible/inventory.yml
|
||||
log_path=/var/log/ansible
|
|
@ -8,6 +8,7 @@
|
|||
- zsh
|
||||
- alpine-zsh-config
|
||||
- bash
|
||||
state: present
|
||||
- name: Populate shell profile
|
||||
template:
|
||||
src: files/shell_profile.j2
|
||||
|
|
Loading…
Reference in a new issue