Class: KuberKit::Core::Artifacts::ArtifactStore
- Defined in:
- lib/kuber_kit/core/artifacts/artifact_store.rb
Instance Method Summary collapse
- #add(artifact) ⇒ Object
- #exists?(artifact_name) ⇒ Boolean
- #get(artifact_name) ⇒ Object
- #get_from_configuration(artifact_name) ⇒ Object
- #get_global(artifact_name) ⇒ Object
- #reset! ⇒ Object
Instance Method Details
#add(artifact) ⇒ Object
2 3 4 |
# File 'lib/kuber_kit/core/artifacts/artifact_store.rb', line 2 def add(artifact) store.add(artifact.name, artifact) end |
#exists?(artifact_name) ⇒ Boolean
29 30 31 |
# File 'lib/kuber_kit/core/artifacts/artifact_store.rb', line 29 def exists?(artifact_name) store.exists?(artifact_name) end |
#get(artifact_name) ⇒ Object
7 8 9 10 11 12 |
# File 'lib/kuber_kit/core/artifacts/artifact_store.rb', line 7 def get(artifact_name) artifact = get_from_configuration(artifact_name) || get_global(artifact_name) artifact end |
#get_from_configuration(artifact_name) ⇒ Object
20 21 22 23 |
# File 'lib/kuber_kit/core/artifacts/artifact_store.rb', line 20 def get_from_configuration(artifact_name) artifacts = KuberKit.current_configuration.artifacts artifacts[artifact_name] end |
#get_global(artifact_name) ⇒ Object
15 16 17 |
# File 'lib/kuber_kit/core/artifacts/artifact_store.rb', line 15 def get_global(artifact_name) store.get(artifact_name) end |
#reset! ⇒ Object
25 26 27 |
# File 'lib/kuber_kit/core/artifacts/artifact_store.rb', line 25 def reset! store.reset! end |