Class: Kuby::Docker::Debian

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

Constant Summary collapse

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Distro

#initialize

Constructor Details

This class inherits a constructor from Kuby::Docker::Distro

Instance Attribute Details

#phaseObject (readonly)

T::Sig::WithoutRuntime.sig { returns(Layer) }



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

def phase
  @phase
end

Instance Method Details

#default_packagesObject

T::Sig::WithoutRuntime.sig { override.returns(T::Array[[Symbol, T.nilable(String)]]) }



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

def default_packages
  DEFAULT_PACKAGES
end

#install(packages, into:) ⇒ Object

T::Sig::WithoutRuntime.sig { override.params(packages: T::Array, into: Dockerfile).void }



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

T::Sig::WithoutRuntime.sig { override.returns(String) }



30
31
32
# File 'lib/kuby/docker/debian.rb', line 30

def shell_exe
  SHELL_EXE
end