Skip to content

Instantly share code, notes, and snippets.

@felipellrocha
Created February 4, 2014 16:41
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 felipellrocha/4da41cb6de08cab6507a to your computer and use it in GitHub Desktop.
Save felipellrocha/4da41cb6de08cab6507a to your computer and use it in GitHub Desktop.
127.0.0.1 localhost
# The following lines are desirable for IPv6 capable hosts
::1 ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters
{% for host, hostinfo in salt['mine.get']('*', 'network.interfaces').items() %}
{{ hostinfo['eth0']['inet'][0]['address'] if hostinfo['eth0'].has_key('inet') else hostinfo['br0']['inet'][0]['address'] }}
{% endfor %}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment