summaryrefslogtreecommitdiffstats
path: root/lib/private/Setup.php
diff options
context:
space:
mode:
Diffstat (limited to 'lib/private/Setup.php')
-rw-r--r--lib/private/Setup.php11
1 files changed, 8 insertions, 3 deletions
diff --git a/lib/private/Setup.php b/lib/private/Setup.php
index c0246a83e46..212deeeba0f 100644
--- a/lib/private/Setup.php
+++ b/lib/private/Setup.php
@@ -325,15 +325,20 @@ class Setup {
$secret = $this->random->generate(48);
//write the config file
- $this->config->setValues([
+ $newConfigValues = [
'passwordsalt' => $salt,
'secret' => $secret,
'trusted_domains' => $trustedDomains,
'datadirectory' => $dataDir,
- 'overwrite.cli.url' => $request->getServerProtocol() . '://' . $request->getInsecureServerHost() . \OC::$WEBROOT,
'dbtype' => $dbType,
'version' => implode('.', \OCP\Util::getVersion()),
- ]);
+ ];
+
+ if ($this->config->getValue('overwrite.cli.url', null) === null) {
+ $newConfigValues['overwrite.cli.url'] = $request->getServerProtocol() . '://' . $request->getInsecureServerHost() . \OC::$WEBROOT;
+ }
+
+ $this->config->setValues($newConfigValues);
try {
$dbSetup->initialize($options);