Class: Docker::Template::Normal
- Defined in:
- lib/docker/template/normal.rb
Constant Summary
Constants inherited from Builder
Builder::ALIAS_SETUP, Builder::SETUP
Instance Attribute Summary
Attributes inherited from Builder
Instance Method Summary collapse
-
#setup_context ⇒ Object
———————————————————————-.
- #teardown(img: false) ⇒ Object
Methods inherited from Builder
#alias?, #aliased_img, #build, #initialize, #normal?, #push, #rootfs?, #scratch?
Constructor Details
This class inherits a constructor from Docker::Template::Builder
Instance Method Details
#setup_context ⇒ Object
18 19 20 21 22 23 |
# File 'lib/docker/template/normal.rb', line 18 def setup_context @context = @repo.tmpdir @copy = @context.join("copy") copy_dockerfile @copy.mkdir end |
#teardown(img: false) ⇒ Object
10 11 12 13 14 |
# File 'lib/docker/template/normal.rb', line 10 def teardown(img: false) @img.delete "force" => true if @img && img @context.rmtree if @context && \ @context.directory? end |