add VAULT_ADDR to script file
- copy:
dest: "./vaultenv.sh"
mode: 0700
- content: "export VAULT_TOKEN='{{vault_init['root_token']}}'\nexport VAULT_KEYS='{{vault_init['keys'] | join(' ')}}'"
+ content: "export VAULT_ADDR='{{lookup('env','VAULT_ADDR')}}'\nexport VAULT_TOKEN='{{vault_init['root_token']}}'\nexport VAULT_KEYS='{{vault_init['keys'] | join(' ')}}'"
when: "vault_init.changed == True"
