diff --git a/README.md b/README.md index 6f9efbb..065d635 100644 --- a/README.md +++ b/README.md @@ -16,11 +16,14 @@ locally to ensure they work properly. Launch playbook on the fly on a host not declared in the inventory. ``` -ansible-playbook -u root -i , [--tags tag1,tag2] playbooks/test.yml +./run-playbook.sh -i , [--tags tag1,tag2] playbooks/test.yml ``` *Note the comma at the end of the hostname or IP.* +When running playbooks that use the vault, the *vault-playbook.sh* script can +be used, it is ovelay over the original *ansible-playbook* command. + ## Manage vault Place vault password into *.vaultpass* file. diff --git a/ansible.cfg b/ansible.cfg index a6fd83b..2d15a49 100644 --- a/ansible.cfg +++ b/ansible.cfg @@ -5,7 +5,6 @@ roles_path = ./roles inventory = ./inventories/production gathering = smart interpreter_python = auto_silent -vault_password_file = .vaultpass [privilege_escalation] become = True diff --git a/vault-playbook.sh b/vault-playbook.sh new file mode 100755 index 0000000..0a1398a --- /dev/null +++ b/vault-playbook.sh @@ -0,0 +1,2 @@ +#!/bin/bash +ansible-playbook --vault-password-file .vaultpass $@