Class: Crowbar::Client::App::Database
- Defined in:
- lib/crowbar/client/app/database.rb
Overview
A Thor based CLI wrapper for batch commands
Instance Method Summary collapse
-
#connect ⇒ String
Database connect command.
-
#create ⇒ String
Database create command.
-
#test ⇒ String
Database test command.
Methods inherited from Base
banner, handle_argument_error, #initialize
Constructor Details
This class inherits a constructor from Crowbar::Client::App::Base
Instance Method Details
#connect ⇒ String
Database connect command
it will connect to a remote Crowbar database before Crowbar installation. This command only works if Crowbar is not yet installed.
135 136 137 138 139 140 141 |
# File 'lib/crowbar/client/app/database.rb', line 135 def connect Command::Database::Connect.new( *command_params ).execute rescue => e catch_errors(e) end |
#create ⇒ String
Database create command
it will set up a new Crowbar database before Crowbar installation. This command only works if Crowbar is not yet installed.
60 61 62 63 64 65 66 |
# File 'lib/crowbar/client/app/database.rb', line 60 def create Command::Database::Create.new( *command_params ).execute rescue => e catch_errors(e) end |
#test ⇒ String
Database test command
it will test the connection to a remote Crowbar database before Crowbar installation. This command only works if Crowbar is not yet installed.
210 211 212 213 214 215 216 |
# File 'lib/crowbar/client/app/database.rb', line 210 def test Command::Database::Test.new( *command_params ).execute rescue => e catch_errors(e) end |