Class: Anvil::App::Env
- Inherits:
-
Struct
- Object
- Struct
- Anvil::App::Env
- Includes:
- ConfigurationReader
- Defined in:
- lib/anvil/app/env.rb
Instance Attribute Summary collapse
-
#configuration ⇒ Object
Returns the value of attribute configuration.
-
#host ⇒ Object
Returns the value of attribute host.
-
#secrets ⇒ Object
Returns the value of attribute secrets.
Instance Method Summary collapse
Methods included from ConfigurationReader
#configuration_for, #configuration_for_app, #environment_for, #environment_for_app, #hosts, #user_for, #validate
Instance Attribute Details
#configuration ⇒ Object
Returns the value of attribute configuration
6 7 8 |
# File 'lib/anvil/app/env.rb', line 6 def configuration @configuration end |
#host ⇒ Object
Returns the value of attribute host
6 7 8 |
# File 'lib/anvil/app/env.rb', line 6 def host @host end |
#secrets ⇒ Object
Returns the value of attribute secrets
6 7 8 |
# File 'lib/anvil/app/env.rb', line 6 def secrets @secrets end |
Instance Method Details
#call ⇒ Object
9 10 11 12 13 |
# File 'lib/anvil/app/env.rb', line 9 def call self.host ||= hosts.first validate host [env_vars_for(host), env_vars_for_app, secrets].compact.join(" ").strip end |