Hi,
I am currently upgrading from ansible 1.7 to 1.8 and my current playbooks are not working anymore. I have batch_size defined in a vars_file and I would like to use this as my serial size.
My playbook looks like this:
---
- hosts: 127.0.0.1
serial: "{{ batch_size }}"
vars_files:
- params/{{ env }}/params.yml
And the error is:
ValueError: invalid literal for int() with base 10: '{{ batch_size }}'I tried also tried using group vars, same issue.
This also works
vars:
batch_size: 2
But this didn't
vars_files:
- params/{{ env }}/params.ymlvars:
batch_size_var: "{{ batch_size }}"Using the -e flag works but I want to keep the variable next to my other variables in params.yml.
I currently changed everything to serial: 50%, but there should be better solution.
What am I doing wrong?