Upgrading Mediawiki: Difference between revisions
(Created page with "In the following instructions, `eb_deploy` refers to the shell script found in the `littled_wiki` project root. * Download new wiki distribution to `littled_wiki` project roo...") |
No edit summary |
||
| Line 1: | Line 1: | ||
== Procedure == | |||
In the following instructions, `eb_deploy` refers to the shell script found in the `littled_wiki` project root. | In the following instructions, `eb_deploy` refers to the shell script found in the `littled_wiki` project root. | ||
| Line 15: | Line 17: | ||
** Do not store any sensitive information in the configuration file. | ** Do not store any sensitive information in the configuration file. | ||
** Custom extensions which would be found at the very end of the file. | ** Custom extensions which would be found at the very end of the file. | ||
== Troubleshooting == | |||
=== Extensions === | |||
==== BacktickCode ==== | |||
Enabling the BacktickCode extension in `LocalSettings.php` causes a 500 error. | |||
Search for "Mediawiki backtick" will point to [https://www.mediawiki.org/wiki/Extension:BacktickCode this page]. The information on that page is out of date. | |||
The current version of Mediawiki loads extensions with `wfLoadExtension()` not `$wgHooks`. Make sure the code for BacktickCode uses a class named `BacktickCode` and not `$wgHooks`. | |||
Also, the current Mediawiki distribution requires an `extension.json` file in the extension directory. The directory without this file will result in a 500 error. | |||
If the BacktickCode extension is causing 500 errors, it can be disabled by commenting out the `wfLoadExtension('BacktickCode')` call in `LocalSettings.php`. | |||
[[Category:Wiki Customization]] | [[Category:Wiki Customization]] | ||
Revision as of 00:08, 23 November 2021
Procedure
In the following instructions, eb_deploy refers to the shell script found in the littled_wiki project root.
- Download new wiki distribution to
littled_wikiproject root. - Edit
eb_deploy.- Change
WIKI_DISTRO_DIRto point to the directory containing the new wiki distribution.
- Change
- Make backup of previous wiki configuration
- Backup the current wiki database.
- Make sure to save a copy of the current
LocalSettings.phpfor the wiki to migrate any custom settings to the new wiki distribution.
- Run
eb_deploy. - Connect to the wiki on the live server.
- Go through the installation steps to create
LocalSettings.php. - Download the newly created
LocalSettings.phpfrom the server to[littled_wiki_PROJECT_ROOT]/wiki_config/
- Go through the installation steps to create
- Migrate settings from previous
LocalSettings.phpto the new file.- Database settings, e.g.
$wgDBServer = getenv('MEDIAWIKI_DB_SERVER'); - Do not store any sensitive information in the configuration file.
- Custom extensions which would be found at the very end of the file.
- Database settings, e.g.
Troubleshooting
Extensions
BacktickCode
Enabling the BacktickCode extension in LocalSettings.php causes a 500 error.
Search for "Mediawiki backtick" will point to this page. The information on that page is out of date.
The current version of Mediawiki loads extensions with wfLoadExtension() not $wgHooks. Make sure the code for BacktickCode uses a class named BacktickCode and not $wgHooks.
Also, the current Mediawiki distribution requires an extension.json file in the extension directory. The directory without this file will result in a 500 error.
If the BacktickCode extension is causing 500 errors, it can be disabled by commenting out the wfLoadExtension('BacktickCode') call in LocalSettings.php.