Hi Team,
While im running below command im getting below error.
vagrant@ubuntu:~/git/ansible-playbooks/playbooks/elasticsearch$ ansible-playbook -i zurich_test_vm -e @variables.yaml -u ansible -e “ansible_ssh_private_key_file=ansible_id_rsa” …/…/two-factor-authentication.yaml --vault-id datalaka-auth@prompt --vault-id zurich_es01@prompt -vvvv
TASK [datalake-auth : Loading secrets from vault.yml] ********************************************************************************************************
task path: /home/vagrant/git/ansible-playbooks/roles/datalake-auth/tasks/main.yml:2
fatal: [tester.cdo-infra-elasticsearch-test.zc2.ibm.com]: FAILED! => {
“ansible_facts”: {},
“ansible_included_var_files”: ,
“changed”: false,
“message”: “Could not find or access ‘/home/vagrant/git/ansible-playbooks/playbooks/elasticsearch/vault.yaml’ on the Ansible Controller.\nIf you are using a module and expect the file to exist on the remote, see the remote_src option”
}
PLAY RECAP ***************************************************************************************************************************************************
tester.cdo-infra-elasticsearch-test.zc2.ibm.com : ok=1 changed=0 unreachable=0 failed=1 skipped=0 rescued=0 ignored=0
vagrant@ubuntu:~/git/ansible-playbooks/playbooks/elasticsearch$ pwd
/home/vagrant/git/ansible-playbooks/playbooks/elasticsearch
I dont have any vault in this directory
vagrant@ubuntu:~/git/ansible-playbooks/playbooks/elasticsearch$ ls vault*
ls: cannot access ‘vault*’: No such file or directory
I have vault under my group_vars
vagrant@ubuntu:~/git/ansible-playbooks/playbooks/elasticsearch/group_vars/zurich_es01$ ls -lrt
total 4
-rw------- 1 vagrant vagrant 1715 May 22 16:09 vault
and under my role
vagrant@ubuntu:~/git/ansible-playbooks/roles/datalake-auth/vars$ ls -lrt
total 24
-rw-rw-r-- 1 vagrant vagrant 1327 May 22 05:18 vault.yml
I want to use the above two files and i have used the above command but still it is throwing error.
Champs any help much appreciated.
Thanks a lot