The following ansible snippet worked fine in 1.7, but throws an error in 1.8. I suspect it has something to do with the {% … %} string I’m trying to insert into the file. I tried different ways to escape it, but can’t find the solution.
What I really want is to add that line to the file. Templating would mean that I need to change my template everytime the original file changes.
I tried to template it anyway, but it also gives me an error since the content of the file contains curly braces. Apparently there used to be a way to change the variable_start_string, but that feature has been removed. It seems that I need to wait for this issue to be resolved first: https://github.com/ansible/ansible/issues/10031