Hi,

I am using Ansible from a Debian testing host. Each time I try to use a 
vault file it makes Ansible crash. The content of the vault file is really 
simple: 

dyndns_pwd: 1234
smtpd_pwd: 1234

I am sure that it contains only ASCII characters.
Here is the command line I use:

ansible-playbook -i host.ini -bkK --vault-id @prompt main.yml -vvv

Here is the log:



TASK [include_vars] 
******************************************************************************************************************************************************************************
task path: /some/path/to/playbook/main.yml:33
The full traceback is:
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/ansible/executor/task_executor.py", 
line 139, in run
    res = self._execute()
  File "/usr/lib/python2.7/dist-packages/ansible/executor/task_executor.py", 
line 603, in _execute
    result = self._handler.run(task_vars=variables)
  File 
"/usr/lib/python2.7/dist-packages/ansible/plugins/action/include_vars.py", 
line 131, in run
    self._load_files(self.source_file)
  File 
"/usr/lib/python2.7/dist-packages/ansible/plugins/action/include_vars.py", 
line 236, in _load_files
    b_data, show_content = self._loader._get_file_contents(filename)
  File "/usr/lib/python2.7/dist-packages/ansible/parsing/dataloader.py", 
line 162, in _get_file_contents
    return self._decrypt_if_vault_data(data, b_file_name)
  File "/usr/lib/python2.7/dist-packages/ansible/parsing/dataloader.py", 
line 132, in _decrypt_if_vault_data
    b_data = self._vault.decrypt(b_vault_data, filename=b_file_name)
  File "/usr/lib/python2.7/dist-packages/ansible/parsing/vault/__init__.py", 
line 658, in decrypt
    plaintext, vault_id, vault_secret = self.decrypt_and_get_vault_id(
vaulttext, filename=filename)
  File "/usr/lib/python2.7/dist-packages/ansible/parsing/vault/__init__.py", 
line 743, in decrypt_and_get_vault_id
    display.vvvvv('Decrypt%s successful with secret=%s and vault_id=%s' % (
file_slug, vault_secret, vault_secret_id))
UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 36: 
ordinal not in range(128)

fatal: [home-server]: FAILED! => {
    "msg": "Unexpected failure during module execution.", 
    "stdout": ""
}

Would you have any hint?

Thanks in advance,
Yvan

-- 
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/7bd319bf-9d41-45a5-bfe9-a7bc1b4e2727%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to