ansible-roles/etc-git/README.md
Jérémy Lecour 08ee315148 etc-git: add a task to commit
It can be invoked in pre/post tasks or anywhere in anther role.
2017-04-25 10:10:17 +02:00

32 lines
638 B
Markdown

# etc-git
Put /etc under Git version control.
## Tasks
The main part (installation and configuration) is in the `tasks/main.yml` file.
There is also an independant task that can be executed to commit changes made in `/etc/.git`, for example when a playbook is run :
```
- name: My Splendid Playbook
[…]
pre_tasks:
- include_role:
name: etc-git
task_from: commit.yml
vars:
commit_message: "Ansible pre-run my splendid playbook"
roles :
[…]
post_tasks:
- include_role:
name: etc-git
task_from: commit.yml
vars:
commit_message: "Ansible pre-run my splendid playbook"
```