Skip to content

Instantly share code, notes, and snippets.

@alexharv074
Created December 17, 2015 08:26
Show Gist options
  • Save alexharv074/a7cf62628466d5ca1ca4 to your computer and use it in GitHub Desktop.
Save alexharv074/a7cf62628466d5ca1ca4 to your computer and use it in GitHub Desktop.
alexs-mbp:playbooks-internal-d291702 alexharvey$ cat roles/nginx/templates//stream.conf.j2
#{{ ansible_managed }}
{% for v in nginx_streams[item] %}
{% if v != "" %}
{{ v.replace(";",";\n ").replace(" {"," {\n ").replace(" }"," \n }\n") }}
{% if v.find('{') == -1%};
{% endif %}
{% endif %}
{% endfor %}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment