Correctly append the port to the host so it's written to the config correctly

Signed-off-by: Joas Schilling <coding@schilljs.com>
This commit is contained in:
Joas Schilling 2020-02-05 12:47:08 +01:00
parent fca8f061ab
commit 0317c5b5c8
No known key found for this signature in database
GPG Key ID: 7076EA9751AACDDA
1 changed files with 4 additions and 1 deletions

View File

@ -134,6 +134,10 @@ class Install extends Command {
} else {
$dbHost = $input->getOption('database-host');
}
if ($dbPort) {
// Append the port to the host so it is the same as in the config (there is no dbport config)
$dbHost .= ':' . $dbPort;
}
$dbTablePrefix = 'oc_';
if ($input->hasParameterOption('--database-table-prefix')) {
$dbTablePrefix = (string) $input->getOption('database-table-prefix');
@ -183,7 +187,6 @@ class Install extends Command {
'dbpass' => $dbPass,
'dbname' => $dbName,
'dbhost' => $dbHost,
'dbport' => $dbPort,
'dbtableprefix' => $dbTablePrefix,
'adminlogin' => $adminLogin,
'adminpass' => $adminPassword,