Class: Kitchen::Provisioner::Base
- Inherits:
-
Object
- Object
- Kitchen::Provisioner::Base
- Defined in:
- lib/kitchen/helpers.rb
Instance Method Summary collapse
Instance Method Details
#create_sandbox ⇒ Object
111 112 113 114 115 |
# File 'lib/kitchen/helpers.rb', line 111 def create_sandbox info("Creating local sandbox in #{sandbox_path}") FileUtils.mkdir_p(sandbox_path) File.chmod(0755, sandbox_path) end |
#instance_name ⇒ Object
121 122 123 124 |
# File 'lib/kitchen/helpers.rb', line 121 def instance_name prefix = (Digest::SHA2.hexdigest FileUtils.pwd)[0, 10] "#{prefix}-#{instance.name}" end |
#sandbox_path ⇒ Object
117 118 119 |
# File 'lib/kitchen/helpers.rb', line 117 def sandbox_path "#{Dir.home}/.dokken/sandbox/#{instance_name}" end |