[chef] Re: How do I configure /etc/network/interfaces using chef?


Chronological Thread 
  • From: Sean OMeara < >
  • To:
  • Subject: [chef] Re: How do I configure /etc/network/interfaces using chef?
  • Date: Thu, 20 Mar 2014 09:38:14 -0400

The best and easiest place to start is "how do you configure them without Chef?"

You manipulate files under /etc.

With Chef, you'd start by identifying those files, and putting them under Chef management.

# In a recipe
template '/etc/network/interfaces' do
  action :create
  source 'interfaces.erb'
end

# copy yourserver:/etc/network/interfaces into your cookbook under templates/default/interfaces.erb

From, there you can start rendering data into this templates.

template '/etc/network/interfaces' do
  action :create
  source 'interfaces.erb'
  variables(

  )
end





On Wed, Mar 19, 2014 at 11:10 AM, Maciek Misztal < " target="_blank"> > wrote:
I'm looking for a way to configure N (N=3) ubuntu nodes with 2 network interfaces each - since I'm a complete newb, what is the proper way to do it?

Regards,
Maciej




Archive powered by MHonArc 2.6.16.

§