Class: KuberKit::Core::Configuration

Inherits:
Object
  • Object
show all
Defined in:
lib/kuber_kit/core/configuration.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(name:, artifacts:, registries:, env_files:, templates:, kubeconfig_path:, deploy_strategy:, services_attributes:) ⇒ Configuration

Returns a new instance of Configuration.



14
15
16
17
18
19
20
21
22
23
# File 'lib/kuber_kit/core/configuration.rb', line 14

def initialize(name:, artifacts:, registries:, env_files:, templates:, kubeconfig_path:, deploy_strategy:, services_attributes:)
  @name             = name
  @artifacts        = artifacts
  @registries       = registries
  @env_files        = env_files
  @templates        = templates
  @kubeconfig_path  = kubeconfig_path
  @deploy_strategy  = deploy_strategy
  @services_attributes = services_attributes
end

Instance Attribute Details

#artifacts ⇒ Object (readonly)

Returns the value of attribute artifacts.



2
3
4
# File 'lib/kuber_kit/core/configuration.rb', line 2

def artifacts
  @artifacts
end

#deploy_strategy ⇒ Object (readonly)

Returns the value of attribute deploy_strategy.



2
3
4
# File 'lib/kuber_kit/core/configuration.rb', line 2

def deploy_strategy
  @deploy_strategy
end

#env_files ⇒ Object (readonly)

Returns the value of attribute env_files.



2
3
4
# File 'lib/kuber_kit/core/configuration.rb', line 2

def env_files
  @env_files
end

#kubeconfig_path ⇒ Object (readonly)

Returns the value of attribute kubeconfig_path.



2
3
4
# File 'lib/kuber_kit/core/configuration.rb', line 2

def kubeconfig_path
  @kubeconfig_path
end

#name ⇒ Object (readonly)

Returns the value of attribute name.



2
3
4
# File 'lib/kuber_kit/core/configuration.rb', line 2

def name
  @name
end

#registries ⇒ Object (readonly)

Returns the value of attribute registries.



2
3
4
# File 'lib/kuber_kit/core/configuration.rb', line 2

def registries
  @registries
end

#services_attributes ⇒ Object (readonly)

Returns the value of attribute services_attributes.



2
3
4
# File 'lib/kuber_kit/core/configuration.rb', line 2

def services_attributes
  @services_attributes
end

#templates ⇒ Object (readonly)

Returns the value of attribute templates.



2
3
4
# File 'lib/kuber_kit/core/configuration.rb', line 2

def templates
  @templates
end

Instance Method Details

#service_attributes(service_name) ⇒ Object



25
26
27
# File 'lib/kuber_kit/core/configuration.rb', line 25

def service_attributes(service_name)
  services_attributes[service_name.to_sym] || {}
end