Class: Dapp::Builder::Chef

Inherits:
Base
  • Object
show all
Defined in:
lib/dapp/builder/chef.rb,
lib/dapp/builder/chef/berksfile.rb,
lib/dapp/builder/chef/cookbook_metadata.rb

Overview

Chef

Defined Under Namespace

Classes: Berksfile, CookbookMetadata

Constant Summary collapse

LOCAL_COOKBOOK_PATTERNS =
%w(
  recipes/**/*
  files/**/*
  templates/**/*
).freeze
STAGE_LOCAL_COOKBOOK_PATTERNS =
%w(
  metadata.json
  recipes/%{stage}.rb
  recipes/*_%{stage}.rb
  files/default/%{stage}/*
  templates/default/%{stage}/*
).freeze
DEFAULT_CHEFDK_IMAGE =

TODO: config, DSL, DEFAULT_CHEFDK_IMAGE

'dappdeps/chefdk:0.17.3-1'.freeze

Instance Attribute Summary

Attributes inherited from Base

#application

Instance Method Summary collapse

Methods inherited from Base

#app_install, #app_install_checksum, #app_setup, #app_setup_checksum, #infra_install, #infra_install_checksum, #infra_setup, #infra_setup_checksum, #initialize

Constructor Details

This class inherits a constructor from Dapp::Builder::Base

Instance Method Details

#chef_cookbooks(image) ⇒ Object



44
45
46
47
48
49
# File 'lib/dapp/builder/chef.rb', line 44

def chef_cookbooks(image)
  image.add_commands(
    "mkdir -p /usr/share/dapp/chef_repo",
    "cp -a #{container_cookbooks_vendor_path} /usr/share/dapp/chef_repo/cookbooks"
  )
end

#chef_cookbooks_checksum ⇒ Object



40
41
42
# File 'lib/dapp/builder/chef.rb', line 40

def chef_cookbooks_checksum
  stage_cookbooks_checksum(:chef_cookbooks)
end