Skip to content

Commit 24b14d8

Browse files
committed
Add database script for MediaWiki 1.43
1 parent 7b1f1de commit 24b14d8

4 files changed

Lines changed: 1206 additions & 4 deletions

File tree

database/mw/README.md

Lines changed: 19 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ This directory contains the SQL needed to create and wiki DBs.
1111

1212
**Versions**
1313

14+
- mw1.43-wbs1 - First 1.43 install
1415
- mw1.39-wbs1 - First 1.39 install
1516
- mw1.38-wbs1 - First 1.38 install
1617
- mw1.35-wbs1 - First 1.35 install
@@ -26,9 +27,25 @@ This directory contains the SQL needed to create and wiki DBs.
2627
Make sure you have updated the docker-compose-clean.yml to:
2728

2829
- For adding extensions?
29-
- Include the latest version of the Mediawiki image with the new code added but not loaded (for extensions)
3030
- Update maintWikWiki.json to match the defaults needs to load all extension from the mw image
3131

32+
33+
**Preparing the MediaWiki image:**
34+
35+
Checkout the [wbstack/mediawiki](https://github.com/wbstack/mediawiki) repository and navigate to it.
36+
37+
Remove any empty extension directories generated by the sync script. You can use the following command to help locate them if they exist:
38+
39+
```
40+
git clean -nd
41+
```
42+
43+
Build the image locally using:
44+
45+
```
46+
docker build -t local-wbaas-mediawiki .
47+
```
48+
3249
**Start the setup:**
3350

3451
```
@@ -62,7 +79,7 @@ cd ./w/extensions/ && ls -dm * | tr -d ' ' | tr -d \\n && cd ./../../
6279

6380
This is an example install command with `WikibaseEdtf` excluded:
6481
```
65-
WBS_DOMAIN=maint php ./w/maintenance/install.php --dbserver sql-clean --dbuser root --dbpass toor --dbname wiki --extensions AdvancedSearch,Auth_remoteuser,CirrusSearch,Cite,CodeEditor,CodeMirror,ConfirmAccount,ConfirmEdit,DeleteBatch,Echo,Elastica,EmbedVideo,EntitySchema,Gadgets,Graph,InviteSignup,JsonConfig,Kartographer,Mailgun,Math,MobileFrontend,MultimediaViewer,Nuke,OAuth,PageImages,ParserFunctions,Poem,Popups,RevisionSlider,Score,Scribunto,SecureLinkFixer,SpamBlacklist,StopForumSpam,SyntaxHighlight_GeSHi,TemplateData,TemplateSandbox,TextExtracts,Thanks,ThatSrc,TorBlock,TwoColConflict,UniversalLanguageSelector,WikiEditor,WikiHiero,Wikibase,WikibaseCirrusSearch,WikibaseExampleData,WikibaseInWikitext,WikibaseLexeme,WikibaseLexemeCirrusSearch,WikibaseManifest,cldr --pass AdminPass0 SiteName AdminName
82+
WBS_DOMAIN=maint php ./w/maintenance/install.php --dbserver sql-clean --dbuser root --dbpass toor --dbname wiki --extensions AdvancedSearch,Auth_remoteuser,CirrusSearch,Cite,CodeEditor,CodeMirror,ConfirmAccount,ConfirmEdit,DeleteBatch,DismissableSiteNotice,Echo,Elastica,EmbedVideo,EntitySchema,Gadgets,InviteSignup,JsonConfig,Kartographer,Mailgun,Math,MobileFrontend,MultimediaViewer,Nuke,OAuth,PageImages,ParserFunctions,Poem,RevisionSlider,Score,Scribunto,SecureLinkFixer,SpamBlacklist,StopForumSpam,SyntaxHighlight_GeSHi,TemplateData,TemplateSandbox,TextExtracts,Thanks,ThatSrc,TorBlock,TwoColConflict,UniversalLanguageSelector,VisualEditor,WikiEditor,WikiHiero,Wikibase,WikibaseCirrusSearch,WikibaseExampleData,WikibaseInWikitext,WikibaseLexeme,WikibaseLexemeCirrusSearch,WikibaseManifest,cldr --pass AdminPass0 SiteName AdminName
6683
```
6784

6885
**While** https://phabricator.wikimedia.org/T267809 is broken you'll then need to edit the auto generated LocalSettings.php file...

database/mw/cleanSql.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
// TODO allow passing in file? or run for all files?
88
$placeholder = '<<prefix>>_';
9-
$filename = __DIR__.'/new/mw1.39-wbs1.sql';
9+
$filename = __DIR__.'/new/mw1.43-wbs1.sql';
1010

1111
// Get the file
1212
$text = file_get_contents($filename);

database/mw/docker-compose-clean.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ version: '3.1'
33
services:
44

55
mediawiki:
6-
image: ghcr.io/wbstack/mediawiki:1.39-7.4-20230328-0
6+
image: local-wbaas-mediawiki
77
volumes:
88
- ./maintWikWiki.json:/var/www/html/w/maintWikWiki.json
99
- ./new:/var/www/html/w/maintenance/wbaas-api/new

0 commit comments

Comments
 (0)