Skip to content

Instantly share code, notes, and snippets.

@justlooks
Created January 24, 2014 06:06
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save justlooks/8592725 to your computer and use it in GitHub Desktop.
Save justlooks/8592725 to your computer and use it in GitHub Desktop.
in pillar file
dsp:
store_category:
- dsp_request
dsp_request:
overhide: yes
type: buffer
in my jinja template file
{% for i in pillar[project]['store_category'] %}
<store>
category={{i}}
type={{pillar[i]['type']}}
{% if pillar[i]['overhide'] == 'yes' %} # abnormal
hi i am overhide
{% else %}
hi i am default
{% endif %}
</store>
{% endfor %}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment