Authored by chunhua.zhang

add global var

... ... @@ -7,3 +7,7 @@ yoho_office_ips:
- 106.39.86.228
- 106.39.86.226
- 106.38.38.147
vault:
server: 'http://10.66.107.2:8200'
token: '27CLyZvYcqawMn7UALUMzRbH'
\ No newline at end of file
... ...
... ... @@ -5,7 +5,7 @@
---
- hosts: 127.0.0.1
vars:
qcloud_key: "{{ lookup('hashi_vault', 'secret=yoho/ops/qcloud token=27CLyZvYcqawMn7UALUMzRbH url=http://10.66.107.2:8200') }}"
qcloud_key: "{{ lookup('hashi_vault', 'secret=yoho/ops/qcloud token=27CLyZvYcqawMn7UALUMzRbH url={{vault.server}}') }}"
tasks:
- name: Installing pip modules for using vault lookup
pip: name={{item}}
... ...