Sha256: 49b07042c426179e728914f84cb734b38cba01b2b74b546dc56b761e641d8ee8

Contents?: true

Size: 1.26 KB

Versions: 22

Compression:

Stored size: 1.26 KB

Contents

class KuberKit::Core::Image
  attr_reader :name, :dependencies, :registry, :dockerfile_path, :build_vars, :build_context_dir, :tag, :before_build_callback, :after_build_callback

  Contract KeywordArgs[
    name:               Symbol,
    dependencies:       ArrayOf[Symbol],
    registry:           Maybe[KuberKit::Core::Registries::Registry],
    dockerfile_path:    String,
    build_vars:         Hash,
    build_context_dir:  Maybe[String],
    tag:                String,
    before_build_callback: Maybe[Proc],
    after_build_callback:  Maybe[Proc]
  ] => Any
  def initialize(name:, dependencies:, registry:, dockerfile_path:, build_vars:, build_context_dir:, tag:, before_build_callback:, after_build_callback:)
    @name = name
    @dependencies = dependencies
    @registry = registry
    @dockerfile_path = dockerfile_path
    @build_vars = build_vars
    @build_context_dir = build_context_dir
    @tag = tag
    @before_build_callback = before_build_callback
    @after_build_callback = after_build_callback
  end

  def registry_url
    "#{registry.path}/#{name}:#{tag}"
  end

  def remote_registry_url
    "#{registry.remote_path}/#{name}:#{tag}"
  end

  def build_args
    puts "WARNING: build_args is deprecated, please use build_vars instead"
    build_vars
  end
end

Version data entries

22 entries across 22 versions & 1 rubygems

Version Path
kuber_kit-0.3.1 lib/kuber_kit/core/image.rb
kuber_kit-0.3.0 lib/kuber_kit/core/image.rb
kuber_kit-0.2.9 lib/kuber_kit/core/image.rb
kuber_kit-0.2.8 lib/kuber_kit/core/image.rb
kuber_kit-0.2.7 lib/kuber_kit/core/image.rb
kuber_kit-0.2.6 lib/kuber_kit/core/image.rb
kuber_kit-0.2.5 lib/kuber_kit/core/image.rb
kuber_kit-0.2.4 lib/kuber_kit/core/image.rb
kuber_kit-0.2.3 lib/kuber_kit/core/image.rb
kuber_kit-0.2.2 lib/kuber_kit/core/image.rb
kuber_kit-0.2.1 lib/kuber_kit/core/image.rb
kuber_kit-0.2.0 lib/kuber_kit/core/image.rb
kuber_kit-0.1.9 lib/kuber_kit/core/image.rb
kuber_kit-0.1.8 lib/kuber_kit/core/image.rb
kuber_kit-0.1.7 lib/kuber_kit/core/image.rb
kuber_kit-0.1.6 lib/kuber_kit/core/image.rb
kuber_kit-0.1.5 lib/kuber_kit/core/image.rb
kuber_kit-0.1.4 lib/kuber_kit/core/image.rb
kuber_kit-0.1.3 lib/kuber_kit/core/image.rb
kuber_kit-0.1.2 lib/kuber_kit/core/image.rb