Class: KuberKit::ImageCompiler::ActionHandler

Inherits:
Object
  • Object
show all
Defined in:
lib/kuber_kit/image_compiler/action_handler.rb

Instance Method Summary collapse

Instance Method Details

#call(shell, image_name, build_id) ⇒ Object



10
11
12
13
14
15
16
17
18
19
20
# File 'lib/kuber_kit/image_compiler/action_handler.rb', line 10

def call(shell, image_name, build_id)
  parent_dir = get_image_compile_parent_dir_for_shell(shell)

  image = image_store.get_image(image_name)

  build_dir_cleaner.call(shell, parent_dir: parent_dir)
  
  compile_dir = generate_compile_dir(parent_dir: parent_dir, build_id: build_id)

  compiler.compile(shell, image, compile_dir)
end