does anyone know if I can merge these dicts in Ansible ? this is within a role if that makes any difference.
--
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 ansible-proje...@googlegroups.com.
To post to this group, send email to ansible...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/CAEhzMJB%3DOFn6zu-75FRxw%3Dric4WttfK0Gzous5cK_Gwi%3DyfCmw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
-- С наилучшими пожеланиями, Андрей Пашкин. м.т - +7 (985) 898 57 59 Skype - waves_in_fluids e-mail - andrew....@gmx.co.uk
To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/CAK5eLPTTD4Mqom0mZH-h-0ZGGGGfnAbT%2BhU9UjmqyrsFWfkjdQ%40mail.gmail.com.
- name: test playbookBut it is desireable to have merge_dicts filter for that.
hosts: 127.0.0.1
connection: local
gather_facts: no
vars:
- somevar: {'a': 1}
- anothervar: {'b': 2}
tasks:
- debug: msg="{{ somevar.update(anothervar) }}{{ somevar }}"
-- With kind regards, Andrew Pashkin. cell phone - +7 (985) 898 57 59
But it is desireable to have merge_dicts filter for that.