Class: RailsOrbit::Configuration
- Inherits:
-
Object
- Object
- RailsOrbit::Configuration
- Defined in:
- lib/rails_orbit/configuration.rb
Constant Summary collapse
- VALID_ADAPTERS =
%i[sqlite host_db external].freeze
Instance Attribute Summary collapse
-
#auth_block ⇒ Object
readonly
Returns the value of attribute auth_block.
-
#dashboard_title ⇒ Object
Returns the value of attribute dashboard_title.
-
#kamal_enabled ⇒ Object
Returns the value of attribute kamal_enabled.
-
#kamal_ssh_key_path ⇒ Object
Returns the value of attribute kamal_ssh_key_path.
-
#poll_interval ⇒ Object
Returns the value of attribute poll_interval.
-
#retention_days ⇒ Object
Returns the value of attribute retention_days.
-
#storage_adapter ⇒ Object
Returns the value of attribute storage_adapter.
-
#storage_url ⇒ Object
Returns the value of attribute storage_url.
Instance Method Summary collapse
- #authenticate_with(&block) ⇒ Object
-
#initialize ⇒ Configuration
constructor
A new instance of Configuration.
- #validate! ⇒ Object
Constructor Details
#initialize ⇒ Configuration
Returns a new instance of Configuration.
10 11 12 13 14 15 16 17 18 19 |
# File 'lib/rails_orbit/configuration.rb', line 10 def initialize @storage_adapter = :sqlite @storage_url = nil @retention_days = 7 @kamal_enabled = false @kamal_ssh_key_path = nil @dashboard_title = "Orbit" @poll_interval = 5 @auth_block = default_auth_block end |
Instance Attribute Details
#auth_block ⇒ Object (readonly)
Returns the value of attribute auth_block.
8 9 10 |
# File 'lib/rails_orbit/configuration.rb', line 8 def auth_block @auth_block end |
#dashboard_title ⇒ Object
Returns the value of attribute dashboard_title.
5 6 7 |
# File 'lib/rails_orbit/configuration.rb', line 5 def dashboard_title @dashboard_title end |
#kamal_enabled ⇒ Object
Returns the value of attribute kamal_enabled.
5 6 7 |
# File 'lib/rails_orbit/configuration.rb', line 5 def kamal_enabled @kamal_enabled end |
#kamal_ssh_key_path ⇒ Object
Returns the value of attribute kamal_ssh_key_path.
5 6 7 |
# File 'lib/rails_orbit/configuration.rb', line 5 def kamal_ssh_key_path @kamal_ssh_key_path end |
#poll_interval ⇒ Object
Returns the value of attribute poll_interval.
5 6 7 |
# File 'lib/rails_orbit/configuration.rb', line 5 def poll_interval @poll_interval end |
#retention_days ⇒ Object
Returns the value of attribute retention_days.
5 6 7 |
# File 'lib/rails_orbit/configuration.rb', line 5 def retention_days @retention_days end |
#storage_adapter ⇒ Object
Returns the value of attribute storage_adapter.
5 6 7 |
# File 'lib/rails_orbit/configuration.rb', line 5 def storage_adapter @storage_adapter end |
#storage_url ⇒ Object
Returns the value of attribute storage_url.
5 6 7 |
# File 'lib/rails_orbit/configuration.rb', line 5 def storage_url @storage_url end |
Instance Method Details
#authenticate_with(&block) ⇒ Object
21 22 23 |
# File 'lib/rails_orbit/configuration.rb', line 21 def authenticate_with(&block) @auth_block = block end |
#validate! ⇒ Object
25 26 27 28 29 |
# File 'lib/rails_orbit/configuration.rb', line 25 def validate! validate_storage_adapter! validate_external_url! validate_kamal_ssh_key! end |