#!/bin/vbash if [ "$(id -g -n)" != 'vyattacfg' ] ; then exec sg vyattacfg -c "/bin/vbash $(readlink -f $0) $@" fi source /opt/vyatta/etc/functions/script-template <% configs[host][:networks].keys.each_with_index do |net, i| %> set interface ethernet eth<%= i+1 %> address <%= configs[host][:networks][net] %> <% end %> commit save