Add ansible Jinja2 template trim

Signed-off-by: Wilfried OLLIVIER <wollivier@bearstech.com>
This commit is contained in:
Wilfried OLLIVIER 2018-01-17 10:11:03 +01:00
parent 5ec528a04c
commit 577262c6a4

View file

@ -23,3 +23,14 @@ ansible-playbook -i host.targets -v site.yml --list-hosts
```shell ```shell
ansible-playbook -i host.targets -v site.yml --limit hostname ansible-playbook -i host.targets -v site.yml --limit hostname
``` ```
## Jinja2, templates & carriage return
To tell Jinja2 to not mess with carriage return in templates add
```
#jinja2: trim_blocks:False
---
```
at the top of the template file