import "sys"
import "util"

$m = {
	"00:11:22:33:44:55" => "hostname1",
	"00:11:22:33:44:56" => "hostname1",
	"aa:bb:cc:dd:ee:fe" => "hostname2",
	"aa:bb:cc:dd:ee:ff" => "hostname2",
}

$h = util.hostname_mapper($m)

print "hostname_mapper" {
	msg => $h,
}

if $h != "" and sys.hostname() != $h {
	hostname "${h}" {} # set it correctly!
}
