r102137 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r102136‎ | r102137 | r102138 >
Date:01:15, 6 November 2011
Author:dantman
Status:resolved (Comments)
Tags:
Comment:
Make the CliInstaller use --server to set wgServer instead of always setting it to "http://localhost"
Modified paths:
  • /trunk/phase3/includes/installer/CliInstaller.php (modified) (history)
  • /trunk/phase3/includes/installer/Installer.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/installer/Installer.php
@@ -853,7 +853,12 @@
854854 * Environment check for the server hostname.
855855 */
856856 protected function envCheckServer() {
857 - $server = WebRequest::detectServer();
 857+ if ( $this->getVar( 'wgServer' ) ) {
 858+ // wgServer was pre-defined, perhaps by the cli installer
 859+ $server = $this->getVar( 'wgServer' );
 860+ } else {
 861+ $server = WebRequest::detectServer();
 862+ }
858863 $this->showMessage( 'config-using-server', $server );
859864 $this->setVar( 'wgServer', $server );
860865 }
Index: trunk/phase3/includes/installer/CliInstaller.php
@@ -27,6 +27,7 @@
2828 'dbport' => 'wgDBport',
2929 'dbschema' => 'wgDBmwschema',
3030 'dbpath' => 'wgSQLiteDataDir',
 31+ 'server' => 'wgServer',
3132 'scriptpath' => 'wgScriptPath',
3233 );
3334

Follow-up revisions

RevisionCommit summaryAuthorDate
r104576Fix r102137. CliInstaller needs to override wgServer, but not in a manner tha...demon17:59, 29 November 2011
r107910MFT r105010, r104671, r104576, r102137reedy17:53, 3 January 2012

Comments

#Comment by Hashar (talk | contribs)   16:08, 28 November 2011

can you also update maintenace/install.php usage function? :-) Thanks!

Status & tagging log