Class: MorpheusHeroku::Config

Inherits:
Object
  • Object
show all
Defined in:
lib/morpheus-heroku/config.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeConfig

Returns a new instance of Config.



5
6
7
8
9
10
11
12
13
# File 'lib/morpheus-heroku/config.rb', line 5

def initialize
  @database_name = if ActiveRecord::Base.respond_to?(:connection_config)
    ActiveRecord::Base.connection_config[:database].dup
  elsif ActiveRecord::Base.respond_to?(:connection_db_config)
    ActiveRecord::Base.connection_db_config.configuration_hash[:database].dup
  end
  @backup_location = "tmp/latest.dump"
  @log_events = false
end

Instance Attribute Details

#app_nameObject

Returns the value of attribute app_name.



3
4
5
# File 'lib/morpheus-heroku/config.rb', line 3

def app_name
  @app_name
end

#backup_locationObject

Returns the value of attribute backup_location.



3
4
5
# File 'lib/morpheus-heroku/config.rb', line 3

def backup_location
  @backup_location
end

#database_nameObject

Returns the value of attribute database_name.



3
4
5
# File 'lib/morpheus-heroku/config.rb', line 3

def database_name
  @database_name
end

#dev_emailObject

Returns the value of attribute dev_email.



3
4
5
# File 'lib/morpheus-heroku/config.rb', line 3

def dev_email
  @dev_email
end

#log_eventsObject

Returns the value of attribute log_events.



3
4
5
# File 'lib/morpheus-heroku/config.rb', line 3

def log_events
  @log_events
end