https://docs.ansible.com/ansible/2.6/network/getting_started/first_inventory.html#protecting-sensitive-variables-with-ansible-vault

says
Copy this output into your inventory file under [vyos:vars], which now 
looks like this:

[vyos:vars]
ansible_connection=network_cli
ansible_network_os=vyos
ansible_user=my_vyos_user
ansible_ssh_pass= !vault |
      $ANSIBLE_VAULT;1.2;AES256;my_user
      
66386134653765386232383236303063623663343437643766386435663632343266393064373933
      
3661666132363339303639353538316662616638356631650a316338316663666439383138353032
      
63393934343937373637306162366265383461316334383132626462656463363630613832313562
      
3837646266663835640a313164343535316666653031353763613037656362613535633538386539
      65656439626166666363323435613131643066353762333232326232323565376635
that is INI style
I put that in a file by itself
and dropped that in the Inventory folder
I got this
[WARNING]:  * Failed to parse /home/MinMe/Ansible/Inventory/test with ini 
plugin: /home/cristi/Ansible/Inventory/test:1: Expected key=value host 
variable assignment, got: this
[WARNING]: Unable to parse /home/MinMe/Ansible/Inventory/test as an 
inventory source

Expected key=value, got: $ANSIBLE_VAULT;1.2;AES256;my_user

guys I must say that it is really frustrating to have to spend so much time 
to encrypt a password and putting it in a configuration file
If Cisco password encryption in the IOS configuration file would be so 
difficult Cisco would not exist today.


Is the documentation wrong ? this was supposed to be easy

-- 
You received this message because you are subscribed to the Google Groups 
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/9dab6852-02ae-4b86-bac5-546b7920f666%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to