Class: Kuby::Docker::Debian

Inherits:
Object
  • Object
show all
Defined in:
lib/kuby/docker/debian.rb

Constant Summary collapse

SHELL_EXE =
'/bin/bash'
DEFAULT_PACKAGES =
[
  [:ca_certificates],
  [:nodejs, '12.14.1'],
  [:yarn, '1.21.1']
].freeze

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(phase) ⇒ Debian

Returns a new instance of Debian.



14
15
16
# File 'lib/kuby/docker/debian.rb', line 14

def initialize(phase)
  @phase = phase
end

Instance Attribute Details

#phaseObject (readonly)

Returns the value of attribute phase.



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

def phase
  @phase
end

Instance Method Details

#default_packagesObject



24
25
26
# File 'lib/kuby/docker/debian.rb', line 24

def default_packages
  DEFAULT_PACKAGES
end

#install(packages, into:) ⇒ Object



18
19
20
21
22
# File 'lib/kuby/docker/debian.rb', line 18

def install(packages, into:)
  dockerfile = into
  install_managed(packages, dockerfile)
  install_unmanaged(packages, dockerfile)
end

#shell_exeObject



28
29
30
# File 'lib/kuby/docker/debian.rb', line 28

def shell_exe
  SHELL_EXE
end