makefile: Reworked prinicple of different playbooks

wip
Felix Stupp 5 years ago
parent 08c85654e4
commit 5c0345f468
Signed by: zocker
GPG Key ID: 93E1BD26F6B02FB7

@ -1,6 +1,17 @@
.PHONY: run vault
run:
ansible-playbook -i hosts --ask-vault-pass site.yml
vault:=group_vars/all/vault.yml
playbooks_dir:=playbooks
playbooks:=$(wildcard ${playbooks_dir}/*.yml)
.PHONY: main list vault ${playbooks}
main:
ansible-playbook site.yml
list:
@echo ${playbooks}
vault:
ansible-vault edit group_vars/all/vault.yml
ansible-vault edit ${vault}
${playbooks}:
ansible-playbook ${playbooks_dir}/$@.yml

Loading…
Cancel
Save