Class: PansophyAuthenticator::Configuration::FromEnv
- Inherits:
-
Object
- Object
- PansophyAuthenticator::Configuration::FromEnv
- Defined in:
- lib/pansophy_authenticator/configuration/from_env.rb
Instance Method Summary collapse
- #application ⇒ Object
- #bucket_name ⇒ Object
- #file_path ⇒ Object
-
#initialize(base_configuration) ⇒ FromEnv
constructor
A new instance of FromEnv.
- #local ⇒ Object
Constructor Details
#initialize(base_configuration) ⇒ FromEnv
Returns a new instance of FromEnv.
4 5 6 |
# File 'lib/pansophy_authenticator/configuration/from_env.rb', line 4 def initialize(base_configuration) @base_configuration = base_configuration end |
Instance Method Details
#application ⇒ Object
21 22 23 |
# File 'lib/pansophy_authenticator/configuration/from_env.rb', line 21 def application ENV.fetch('PANSOPHY_AUTHENTICATOR_APPLICATION') { @base_configuration.application } end |
#bucket_name ⇒ Object
13 14 15 |
# File 'lib/pansophy_authenticator/configuration/from_env.rb', line 13 def bucket_name ENV.fetch('PANSOPHY_AUTHENTICATOR_BUCKET_NAME') { @base_configuration.bucket_name } end |
#file_path ⇒ Object
17 18 19 |
# File 'lib/pansophy_authenticator/configuration/from_env.rb', line 17 def file_path ENV.fetch('PANSOPHY_AUTHENTICATOR_FILE_PATH') { @base_configuration.file_path } end |
#local ⇒ Object
8 9 10 11 |
# File 'lib/pansophy_authenticator/configuration/from_env.rb', line 8 def local local = ENV.fetch('PANSOPHY_AUTHENTICATOR_LOCAL') { @base_configuration.local } local.to_s == 'true' end |