Skip to content

Instantly share code, notes, and snippets.

@evrardjp
Created November 25, 2015 09:55
Show Gist options
  • Save evrardjp/446df7031463e5d4504c to your computer and use it in GitHub Desktop.
Save evrardjp/446df7031463e5d4504c to your computer and use it in GitHub Desktop.
{% set processes = 0 %}
{% for host in groups['swift_hosts'] %}
{% if inventory_hostname in host %}
processid = {{ processes }}
{% else %}
{% set processes = processes + 1 %}
{% endif %}
{% endfor %}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment