Sha256: 68d886396ef4552b746241b4b15c7b2668b6a244e62036c6892155b60cf4ecfa

Contents?: true

Size: 655 Bytes

Versions: 10

Compression:

Stored size: 655 Bytes

Contents

include_recipe 'lxc'

# This shuts down the default lxcbr0
node[:lxc][:use_bridge] = false
service 'lxc' do
  action :stop
end

directory '/etc/knife-lxc' do
  action :create
  mode 0755
end

file '/etc/knife-lxc/config.json' do
  mode 0644
  content(
    JSON.pretty_generate(
      :addresses => {
        :static => node[:lxc][:knife][:static_ips],
        :range => node[:lxc][:knife][:static_range]
      }
    )
  )
end

cookbook_file '/usr/local/bin/knife_lxc' do
  source 'knife_lxc'
  mode 0755
end

node[:lxc][:allowed_types].each do |type|
  lxc_container "#{type}_base" do
    template type
    chef_enabled false
    action :create
  end
end

Version data entries

10 entries across 10 versions & 2 rubygems

Version Path
vagabond-0.2.8 lib/vagabond/cookbooks/lxc/recipes/knife.rb
vagabond-0.2.6 lib/vagabond/cookbooks/lxc/recipes/knife.rb
vagabond-0.2.4 lib/vagabond/cookbooks/lxc/recipes/knife.rb
vagabond-0.2.2 lib/vagabond/cookbooks/lxc/recipes/knife.rb
elecksee-1.0.2 lib/elecksee/vendor/lxc/recipes/knife.rb
elecksee-1.0.0 lib/elecksee/vendor/lxc/recipes/knife.rb
vagabond-0.2.0 lib/vagabond/cookbooks/lxc/recipes/knife.rb
vagabond-0.1.4 lib/vagabond/cookbooks/lxc/recipes/knife.rb
vagabond-0.1.2 lib/vagabond/cookbooks/lxc/recipes/knife.rb
vagabond-0.1.0 lib/vagabond/cookbooks/lxc/recipes/knife.rb