Class: Dip::Config
- Inherits:
-
Object
- Object
- Dip::Config
- Defined in:
- lib/dip/config.rb
Instance Method Summary collapse
- #compose ⇒ Object
- #environment ⇒ Object
-
#initialize(config_path) ⇒ Config
constructor
A new instance of Config.
- #interaction ⇒ Object
- #merge(config) ⇒ Object
- #provision ⇒ Object
Constructor Details
#initialize(config_path) ⇒ Config
Returns a new instance of Config.
8 9 10 |
# File 'lib/dip/config.rb', line 8 def initialize(config_path) load_or_default(config_path) end |
Instance Method Details
#compose ⇒ Object
20 21 22 |
# File 'lib/dip/config.rb', line 20 def compose @config.fetch(:compose, {}) end |
#environment ⇒ Object
16 17 18 |
# File 'lib/dip/config.rb', line 16 def environment @config.fetch(:environment, {}) end |
#interaction ⇒ Object
24 25 26 |
# File 'lib/dip/config.rb', line 24 def interaction @config.fetch(:interaction, {}) end |
#merge(config) ⇒ Object
12 13 14 |
# File 'lib/dip/config.rb', line 12 def merge(config) @config.merge!(config) end |
#provision ⇒ Object
28 29 30 |
# File 'lib/dip/config.rb', line 28 def provision @config.fetch(:provision, []) end |