Class: VBox::WebService::Configuration
- Inherits:
-
Object
- Object
- VBox::WebService::Configuration
- Defined in:
- lib/virtualbox/configuration.rb
Instance Attribute Summary collapse
-
#log_level ⇒ Object
Returns the value of attribute log_level.
-
#logger ⇒ Object
Returns the value of attribute logger.
-
#vboxweb_host ⇒ Object
Returns the value of attribute vboxweb_host.
-
#vboxweb_pass ⇒ Object
Returns the value of attribute vboxweb_pass.
-
#vboxweb_port ⇒ Object
Returns the value of attribute vboxweb_port.
-
#vboxweb_user ⇒ Object
Returns the value of attribute vboxweb_user.
Instance Method Summary collapse
-
#initialize ⇒ Configuration
constructor
A new instance of Configuration.
Constructor Details
#initialize ⇒ Configuration
Returns a new instance of Configuration.
9 10 11 12 13 14 15 16 17 |
# File 'lib/virtualbox/configuration.rb', line 9 def initialize @vboxweb_host = ENV['VBOXWEB_HOST'] || '127.0.0.1' @vboxweb_port = ENV['VBOXWEB_PORT'] || '18083' @vboxweb_user = ENV['VBOXWEB_USER'] @vboxweb_pass = ENV['VBOXWEB_PASS'] @log_level = ENV['VBOXWEB_LOGGING'] || 'ERROR' @logger = Logger.new(STDOUT) @logger.level = Logger.const_get(@log_level) end |
Instance Attribute Details
#log_level ⇒ Object
Returns the value of attribute log_level.
7 8 9 |
# File 'lib/virtualbox/configuration.rb', line 7 def log_level @log_level end |
#logger ⇒ Object
Returns the value of attribute logger.
7 8 9 |
# File 'lib/virtualbox/configuration.rb', line 7 def logger @logger end |
#vboxweb_host ⇒ Object
Returns the value of attribute vboxweb_host.
7 8 9 |
# File 'lib/virtualbox/configuration.rb', line 7 def vboxweb_host @vboxweb_host end |
#vboxweb_pass ⇒ Object
Returns the value of attribute vboxweb_pass.
7 8 9 |
# File 'lib/virtualbox/configuration.rb', line 7 def vboxweb_pass @vboxweb_pass end |
#vboxweb_port ⇒ Object
Returns the value of attribute vboxweb_port.
7 8 9 |
# File 'lib/virtualbox/configuration.rb', line 7 def vboxweb_port @vboxweb_port end |
#vboxweb_user ⇒ Object
Returns the value of attribute vboxweb_user.
7 8 9 |
# File 'lib/virtualbox/configuration.rb', line 7 def vboxweb_user @vboxweb_user end |