Skip to content

Instantly share code, notes, and snippets.

@johnkeates
Created June 8, 2015 12:49
Show Gist options
  • Save johnkeates/4b4411074a5f0300374a to your computer and use it in GitHub Desktop.
Save johnkeates/4b4411074a5f0300374a to your computer and use it in GitHub Desktop.
{%- if 'userlists' in salt['pillar.get']('haproxy', {}) %}
{%- for id, userlist in salt['pillar.get']('haproxy:userlists').iteritems() %}
userlist {{ id }}
{%- for entry in userlist.iteritems() %}
{{ entry }}
{%- endfor %}
{% endfor %}
{% endif %}
@johnkeates
Copy link
Author

haproxy:
  userlists:
    userlist1:
      - user john insecure-password doe
      - user sam insecure-password doe
      - user jekyll insecure-password doe
    userlist2:
      - user jane insecure-password doe
      - user obama insecure-password doe
      - user dude insecure-password doe

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment