Class: KuberKit::EnvFileReader::Strategies::ArtifactFile

Inherits:
Abstract show all
Defined in:
lib/kuber_kit/env_file_reader/strategies/artifact_file.rb

Constant Summary collapse

PREPROCESS_EXTENSIONS =
[".erb"]

Instance Method Summary collapse

Instance Method Details

#read(shell, env_file) ⇒ Object



10
11
12
13
14
15
16
17
# File 'lib/kuber_kit/env_file_reader/strategies/artifact_file.rb', line 10

def read(shell, env_file)
  artifact = artifact_store.get(env_file.artifact_name)

  file_parts = [artifact.cloned_path, env_file.file_path].compact
  file_path  = File.join(*file_parts)

  read_file(shell, file_path)
end