ployground / ploy_ansible

Plugin to integrate Ansible with ploy.
5 stars 4 forks source link

``get_ansible_variables`` only contains variables from ``group_vars/all`` and hostvars #5

Closed tomster closed 10 years ago

tomster commented 10 years ago

i would expect to able to also access variables that have been defined within roles that are applied to the host.

perhaps we would need to trigger ansible's fact gathering first?

fschulze commented 10 years ago

Well, get_ansible_variables doesn't know anything about which playbook is used. We would have to add an option for that.

Fact gathering wouldn't help here. If we add fact gathering, then also only as an option, because it requires ssh access and it's slow.

tomster commented 10 years ago

for now it seems reasonable to simply put all variables that you need to access in both in fabric scripts and in playbooks either in group_vars/all.yml or into host_vars.