Class: Kuby::Docker::InlineLayer

Inherits:
Layer
  • Object
show all
Extended by:
T::Sig
Defined in:
lib/kuby/docker/inline_layer.rb

Instance Attribute Summary collapse

Attributes inherited from Layer

#environment

Instance Method Summary collapse

Constructor Details

#initialize(block) ⇒ InlineLayer

Returns a new instance of InlineLayer.



12
13
14
# File 'lib/kuby/docker/inline_layer.rb', line 12

def initialize(block)
  @block = block
end

Instance Attribute Details

#blockObject (readonly)

Returns the value of attribute block.



9
10
11
# File 'lib/kuby/docker/inline_layer.rb', line 9

def block
  @block
end

Instance Method Details

#apply_to(dockerfile) ⇒ Object



17
18
19
# File 'lib/kuby/docker/inline_layer.rb', line 17

def apply_to(dockerfile)
  block.call(dockerfile)
end