[chef] Cookbook Template: Populating MAC address in ifcfg


Chronological Thread 
  • From: < >
  • To:
  • Subject: [chef] Cookbook Template: Populating MAC address in ifcfg
  • Date: Tue, 1 Oct 2013 18:00:41 -0700 (PDT)


Hello,

I'm trying to set up an ifcfg file using a template.

HWADDR=<%= node[:network][:interfaces][:eth1][:addresses].keys %>

The MAC address populates the file but the entry is surrounded by brackets 
like
below.

HWADDR=["00:00:00:00:00:00"]

How can I get to - HWADDR=00:00:00:00:00:00

or is there a more efficent way to build the file?

Thanks for the help.



Archive powered by MHonArc 2.6.16.

§