From 3e6d38d401782e0c66cc00d6cb20dc212c70f0ba Mon Sep 17 00:00:00 2001 From: Jeffrey Wang Date: Sun, 30 Oct 2022 03:09:41 -0700 Subject: [PATCH 01/67] Add Dockerfile for barebones Canasta (without Canasta-bundled extensions) --- Dockerfile | 510 ++++------------------------------------------------- 1 file changed, 31 insertions(+), 479 deletions(-) diff --git a/Dockerfile b/Dockerfile index 6b74dc07..21e1ea84 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,10 +1,10 @@ -FROM debian:11.4 as base +FROM debian:11.5 as base LABEL maintainers="" LABEL org.opencontainers.image.source=https://github.com/CanastaWiki/Canasta -ENV MW_VERSION=REL1_35 \ - MW_CORE_VERSION=1.35.8 \ +ENV MW_VERSION=REL1_39 \ + MW_CORE_VERSION=1.39.0-rc.1 \ WWW_ROOT=/var/www/mediawiki \ MW_HOME=/var/www/mediawiki/w \ MW_ORIGIN_FILES=/mw_origin_files \ @@ -99,450 +99,23 @@ RUN set -x; \ # CologneBlue && git clone -b $MW_VERSION --single-branch https://gerrit.wikimedia.org/r/mediawiki/skins/CologneBlue $MW_HOME/skins/CologneBlue \ && cd $MW_HOME/skins/CologneBlue \ - && git checkout -q 515a545dfee9f534f74a42057b7a4509076716b4 \ + && git checkout -q 4d588eb78d7e64e574f631c5897579537305437d \ # MinervaNeue - && git clone -b $MW_VERSION --single-branch https://gerrit.wikimedia.org/r/mediawiki/skins/MinervaNeue $MW_HOME/skins/MinervaNeue \ - && cd $MW_HOME/skins/MinervaNeue \ - && git checkout -q 6c99418af845a7761c246ee5a50fbb82715f4003 \ + #&& git clone -b $MW_VERSION --single-branch https://gerrit.wikimedia.org/r/mediawiki/skins/MinervaNeue $MW_HOME/skins/MinervaNeue \ + #&& cd $MW_HOME/skins/MinervaNeue \ + #&& git checkout -q e4741ff2c4375c2befee0d9f350aff6eb6e1a4da \ # Modern && git clone -b $MW_VERSION --single-branch https://gerrit.wikimedia.org/r/mediawiki/skins/Modern $MW_HOME/skins/Modern \ && cd $MW_HOME/skins/Modern \ - && git checkout -q d0a04c91132105f712df4de44a99d3643e7afbba \ + && git checkout -q fb6c2831b5f150e9b82d98d661710695a2d0f8f2 \ # Pivot - && git clone -b v2.3.0 https://github.com/Hutchy68/pivot.git $MW_HOME/skins/pivot \ + && git clone -b v2.3.0 https://github.com/wikimedia/mediawiki-skins-Pivot $MW_HOME/skins/pivot \ && cd $MW_HOME/skins/pivot \ - && git checkout -q -b $MW_VERSION 0d3d6b03a83afd7e1cb170aa41bdf23c0ce3e93b \ + && git checkout -q d79af7514347eb5272936243d4013118354c85c1 \ # Refreshed && git clone -b $MW_VERSION --single-branch https://gerrit.wikimedia.org/r/mediawiki/skins/Refreshed $MW_HOME/skins/Refreshed \ && cd $MW_HOME/skins/Refreshed \ - && git checkout -q 3fad8765c3ec8082bb899239f502199f651818cb - -# Extensions -# The following extensions are bundled into MediaWiki and do not need to be separately installed (though in some cases -# they are modified): CategoryTree, Cite, CiteThisPage, CodeEditor, ConfirmEdit, Gadgets, ImageMap, InputBox, Interwiki, -# LocalisationUpdate, MultimediaViewer, Nuke, OATHAuth, PageImages, ParserFunctions, PdfHandler, Poem, Renameuser, -# Replace Text, Scribunto, SecureLinkFixer, SpamBlacklist, SyntaxHighlight, TemplateData, TextExtracts, TitleBlacklist, -# VisualEditor, WikiEditor. -# The following extensions are downloaded via Composer and also do not need to be downloaded here: Bootstrap, -# BootstrapComponents, Maps, Semantic Breadcrumb Links, Semantic Compound Queries, Semantic Extra Special Properties, -# Semantic MediaWiki (along with all its helper library extensions, like DataValues), Semantic Result Formats, Semantic -# Scribunto, SimpleBatchUpload, SubPageList. -RUN set -x; \ - cd $MW_HOME/extensions \ - # AbuseFilter - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/AbuseFilter $MW_HOME/extensions/AbuseFilter \ - && cd $MW_HOME/extensions/AbuseFilter \ - && git checkout -q 188389ce51055b59f338a6784ecb51b30973e81f \ - # AdminLinks (v. 0.5) - && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/AdminLinks $MW_HOME/extensions/AdminLinks \ - && cd $MW_HOME/extensions/AdminLinks \ - && git checkout -q 303a8a40d0a3db3356174cd2cef1857be9bda5a2 \ - # AdvancedSearch - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/AdvancedSearch $MW_HOME/extensions/AdvancedSearch \ - && cd $MW_HOME/extensions/AdvancedSearch \ - && git checkout -q d1895707f3750a6d4a486b425ac9a727707f27f9 \ - # AJAXPoll - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/AJAXPoll $MW_HOME/extensions/AJAXPoll \ - && cd $MW_HOME/extensions/AJAXPoll \ - && git checkout -q 846bbd16799efb7b279433856a5e85914961314b \ - # AntiSpoof - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/AntiSpoof $MW_HOME/extensions/AntiSpoof \ - && cd $MW_HOME/extensions/AntiSpoof \ - && git checkout -q 1c82ce797d2eefa7f82fb88f82d550c2c73ff3b6 \ - # ApprovedRevs (v. 1.7.3) + Fix for ParserGetVariableValueSwitch hook, it should never return false - && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/ApprovedRevs $MW_HOME/extensions/ApprovedRevs \ - && cd $MW_HOME/extensions/ApprovedRevs \ - && git checkout -q 82d0da854f1f2279482fe56d01d49468b91d0b7f \ - # Arrays - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Arrays $MW_HOME/extensions/Arrays \ - && cd $MW_HOME/extensions/Arrays \ - && git checkout -q e09d74379c191f3e83560d7bb35d39fb4162f0fc \ - # BetaFeatures - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/BetaFeatures $MW_HOME/extensions/BetaFeatures \ - && cd $MW_HOME/extensions/BetaFeatures \ - && git checkout -q 27486070bff17b4886543fe8d888585a722c6a76 \ - # BreadCrumbs2 - && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/BreadCrumbs2.git $MW_HOME/extensions/BreadCrumbs2 \ - && cd $MW_HOME/extensions/BreadCrumbs2 \ - && git fetch "https://gerrit.wikimedia.org/r/mediawiki/extensions/BreadCrumbs2" refs/changes/03/701603/1 \ - && git checkout FETCH_HEAD \ - # Cargo (v. 3.0) - && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/Cargo $MW_HOME/extensions/Cargo \ - && cd $MW_HOME/extensions/Cargo \ - && git checkout -q c9435c2c95098979a8002cb02a937d83ed40e073 \ - # CharInsert - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/CharInsert $MW_HOME/extensions/CharInsert \ - && cd $MW_HOME/extensions/CharInsert \ - && git checkout -q 98fa7c3c8b114a565c2e63e52319ea5382ed695a \ - # CheckUser - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/CheckUser $MW_HOME/extensions/CheckUser \ - && cd $MW_HOME/extensions/CheckUser \ - && git checkout -q 2ec9a1bea7ea93bd96c3db44d320b907e6c28c00 \ - # CirrusSearch - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/CirrusSearch $MW_HOME/extensions/CirrusSearch \ - && cd $MW_HOME/extensions/CirrusSearch \ - && git checkout -q 203237ef2828c46094c5f6ba26baaeff2ab3596b \ - # CodeMirror - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/CodeMirror $MW_HOME/extensions/CodeMirror \ - && cd $MW_HOME/extensions/CodeMirror \ - && git checkout -q 84846ec71fb3be844771025ddd9c039da3cc1616 \ - # Collection - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Collection $MW_HOME/extensions/Collection \ - && cd $MW_HOME/extensions/Collection \ - && git checkout -q c22330cb462cbcb7e01da48b7ab1e0caa4e3841f \ - # CommentStreams - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/CommentStreams $MW_HOME/extensions/CommentStreams \ - && cd $MW_HOME/extensions/CommentStreams \ - && git checkout -q 87522c23e95665c6e2aca11799f7852561fbbe9b \ - # CommonsMetadata - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/CommonsMetadata $MW_HOME/extensions/CommonsMetadata \ - && cd $MW_HOME/extensions/CommonsMetadata \ - && git checkout -q badf499682be04d2b2b1139ae9063fb7b436daa3 \ - # ConfirmAccount - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/ConfirmAccount $MW_HOME/extensions/ConfirmAccount \ - && cd $MW_HOME/extensions/ConfirmAccount \ - && git checkout -q cde8cece830eaeebf66d0d96dc09a206683435c7 \ - # ContactPage - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/ContactPage $MW_HOME/extensions/ContactPage \ - && cd $MW_HOME/extensions/ContactPage \ - && git checkout -q 0466489a8c2ad8f5c045b145cb8b65bb8b164c48 \ - # ContributionScores (v. 1.26.1 - REL1_35 branch does not work with MW 1.35) - && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/ContributionScores $MW_HOME/extensions/ContributionScores \ - && cd $MW_HOME/extensions/ContributionScores \ - && git checkout -q 46ebf438283913f103ba5dd03a3e4730bb9f87dc \ - # CookieWarning - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/CookieWarning $MW_HOME/extensions/CookieWarning \ - && cd $MW_HOME/extensions/CookieWarning \ - && git checkout -q cca62129085d50da90d503823848560ebc8058b4 \ - # DataTransfer (v. 1.4) - && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/DataTransfer $MW_HOME/extensions/DataTransfer \ - && cd $MW_HOME/extensions/DataTransfer \ - && git checkout -q 70b1911e695b3f01d0f3d059308888bc8fec361c \ - # Description2 - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Description2 $MW_HOME/extensions/Description2 \ - && cd $MW_HOME/extensions/Description2 \ - && git checkout -q c471ce36b822e74104a38e302bd59b993c679d72 \ - # Disambiguator - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Disambiguator $MW_HOME/extensions/Disambiguator \ - && cd $MW_HOME/extensions/Disambiguator \ - && git checkout -q 06cae54808417caa72c6fe6702af23da5f4c45c5 \ - # DiscussionTools - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/DiscussionTools $MW_HOME/extensions/DiscussionTools \ - && cd $MW_HOME/extensions/DiscussionTools \ - && git checkout -q 9292f0a6abe8759eb3b44d57b3ea6da05ef8aa95 \ - # DismissableSiteNotice - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/DismissableSiteNotice $MW_HOME/extensions/DismissableSiteNotice \ - && cd $MW_HOME/extensions/DismissableSiteNotice \ - && git checkout -q ad3a7802f78498e748833886613e28b4f7cb91b8 \ - # DisplayTitle - && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/DisplayTitle $MW_HOME/extensions/DisplayTitle \ - && cd $MW_HOME/extensions/DisplayTitle \ - && git checkout -q 4f3f66c524465b26b3ee66029a4500966ba29ab2 \ - # Echo - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Echo $MW_HOME/extensions/Echo \ - && cd $MW_HOME/extensions/Echo \ - && git checkout -q 55c1b2a6de7b9e2d9bc720d7794b097fcd2ef901 \ - # Editcount - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Editcount $MW_HOME/extensions/Editcount \ - && cd $MW_HOME/extensions/Editcount \ - && git checkout -q 978929f63f47ea88764f66ad7903eca65c64df4f \ - # Elastica - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Elastica $MW_HOME/extensions/Elastica \ - && cd $MW_HOME/extensions/Elastica \ - && git checkout -q 8af6b458adf628a98af4ba8e407f9c676bf4a4fb \ - # EmailAuthorization - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/EmailAuthorization $MW_HOME/extensions/EmailAuthorization \ - && cd $MW_HOME/extensions/EmailAuthorization \ - && git checkout -q 5d1594a762427e37f243220578a393e6134aa020 \ - # EmbedVideo - && git clone --single-branch -b master https://gitlab.com/hydrawiki/extensions/EmbedVideo.git $MW_HOME/extensions/EmbedVideo \ - && cd $MW_HOME/extensions/EmbedVideo \ - && git checkout -q 1c2f745b16beb3ee5a176bb8a1d0d03d301a9385 \ - # EventLogging - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/EventLogging $MW_HOME/extensions/EventLogging \ - && cd $MW_HOME/extensions/EventLogging \ - && git checkout -q 71f88485e0bea9c668dec20e018d3da2d444585e \ - # EventStreamConfig - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/EventStreamConfig $MW_HOME/extensions/EventStreamConfig \ - && cd $MW_HOME/extensions/EventStreamConfig \ - && git checkout -q bce5bc385b2919cf294a074b64bc330ac48f78db \ - # ExternalData (v. 3.1) - && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/ExternalData $MW_HOME/extensions/ExternalData \ - && cd $MW_HOME/extensions/ExternalData \ - && git checkout -q 64785b7e2134121d84a77edde9daab5db040e97a \ - # FlexDiagrams (v. 0.4) - && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/FlexDiagrams $MW_HOME/extensions/FlexDiagrams \ - && cd $MW_HOME/extensions/FlexDiagrams \ - && git checkout -q a05d7a450141504cb4df23ef4d077c97d1491228 \ - # GlobalNotice - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/GlobalNotice $MW_HOME/extensions/GlobalNotice \ - && cd $MW_HOME/extensions/GlobalNotice \ - && git checkout -q f86637d27e6be7c60ec12bb8859f4b76cceb1be2 \ - # GoogleAnalyticsMetrics - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/GoogleAnalyticsMetrics $MW_HOME/extensions/GoogleAnalyticsMetrics \ - && cd $MW_HOME/extensions/GoogleAnalyticsMetrics \ - && git checkout -q c292c17b2e1f44f11a82323b48ec2911c384a085 \ - # GoogleDocCreator (v. 2.0) - && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/GoogleDocCreator $MW_HOME/extensions/GoogleDocCreator \ - && cd $MW_HOME/extensions/GoogleDocCreator \ - && git checkout -q a606f4390e4265de227a79a353fee902e6703bd5 \ - # Graph - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Graph $MW_HOME/extensions/Graph \ - && cd $MW_HOME/extensions/Graph \ - && git checkout -q ae2cc41b751a9763792ae861fa3699b9217c5ef9 \ - # HeaderFooter - && git clone https://github.com/enterprisemediawiki/HeaderFooter.git $MW_HOME/extensions/HeaderFooter \ - && cd $MW_HOME/extensions/HeaderFooter \ - && git checkout -q eee7d2c1a3373c7d6b326fd460e5d4859dd22c40 \ - # HeaderTabs (v. 2.2) - && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/HeaderTabs $MW_HOME/extensions/HeaderTabs \ - && cd $MW_HOME/extensions/HeaderTabs \ - && git checkout -q 37679158f93e4ba5a292744b30e2a64d50fb818c \ - # HTMLTags - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/HTMLTags $MW_HOME/extensions/HTMLTags \ - && cd $MW_HOME/extensions/HTMLTags \ - && git checkout -q 3476196e1e46b3cb56035d2151d98797c088bc90 \ - # LabeledSectionTransclusion - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/LabeledSectionTransclusion $MW_HOME/extensions/LabeledSectionTransclusion \ - && cd $MW_HOME/extensions/LabeledSectionTransclusion \ - && git checkout -q 8b0ba6952488763201a0defef0499c743ef933f7 \ - # LDAPAuthentication2 - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/LDAPAuthentication2 $MW_HOME/extensions/LDAPAuthentication2 \ - && cd $MW_HOME/extensions/LDAPAuthentication2 \ - && git checkout -q dabdf2292b272316a2caed901dd7aecf574f8682 \ - # LDAPAuthorization - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/LDAPAuthorization $MW_HOME/extensions/LDAPAuthorization \ - && cd $MW_HOME/extensions/LDAPAuthorization \ - && git checkout -q 149b7c0591795c8c3fae0068f2e7a602b1944453 \ - # LDAPProvider - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/LDAPProvider $MW_HOME/extensions/LDAPProvider \ - && cd $MW_HOME/extensions/LDAPProvider \ - && git checkout -q 8fe016315311619321767809dfef54f0ad28aa1a \ - # Lingo - && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/Lingo $MW_HOME/extensions/Lingo \ - && cd $MW_HOME/extensions/Lingo \ - && git checkout -q d59cdaf9afbb98a0a8b507afdb102a2755dd85a1 \ - # LinkSuggest - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/LinkSuggest $MW_HOME/extensions/LinkSuggest \ - && cd $MW_HOME/extensions/LinkSuggest \ - && git checkout -q 44f905ee4e7ac8349a822bfd9d22f79a1e24e4a4 \ - # LinkTarget - && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/LinkTarget $MW_HOME/extensions/LinkTarget \ - && cd $MW_HOME/extensions/LinkTarget \ - && git checkout -q ab1aba0a4a138f80c4cd9c86cc53259ca0fe4545 \ - # Linter - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Linter $MW_HOME/extensions/Linter \ - && cd $MW_HOME/extensions/Linter \ - && git checkout -q 5c1e56974035e59434970ef8ebe7ea2c9cdd6bf8 \ - # LockAuthor - && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/LockAuthor $MW_HOME/extensions/LockAuthor \ - && cd $MW_HOME/extensions/LockAuthor \ - && git checkout -q ee5ab1ed2bc34ab1b08c799fb1e14e0d5de65953 \ - # Lockdown - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Lockdown $MW_HOME/extensions/Lockdown \ - && cd $MW_HOME/extensions/Lockdown \ - && git checkout -q 4d595408c96190a1c44cfed96f244988fc88054a \ - # LookupUser - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/LookupUser $MW_HOME/extensions/LookupUser \ - && cd $MW_HOME/extensions/LookupUser \ - && git checkout -q 57d8f2df716758f87e2286c52f0bdea78a8a85cf \ - # Loops - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Loops $MW_HOME/extensions/Loops \ - && cd $MW_HOME/extensions/Loops \ - && git checkout -q f0f1191f56e6b31b063f59ee2710a6f62890a336 \ - # MagicNoCache - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/MagicNoCache $MW_HOME/extensions/MagicNoCache \ - && cd $MW_HOME/extensions/MagicNoCache \ - && git checkout -q c0c85db103dce74005cc8e2c1ef877a69b27f0d7 \ - # MassMessage - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/MassMessage $MW_HOME/extensions/MassMessage \ - && cd $MW_HOME/extensions/MassMessage \ - && git checkout -q 4c6be095fcb1eb2d741881773a6b8ef0487871af \ - # MassMessageEmail - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/MassMessageEmail $MW_HOME/extensions/MassMessageEmail \ - && cd $MW_HOME/extensions/MassMessageEmail \ - && git checkout -q 2424d03ac7b53844d49379cba3cceb5d9f4b578e \ - # Math - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Math $MW_HOME/extensions/Math \ - && cd $MW_HOME/extensions/Math \ - && git checkout -q ce438004cb7366860d3bff1f60839ef3c304aa1e \ - # MintyDocs (v. 0.9) - && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/MintyDocs $MW_HOME/extensions/MintyDocs \ - && cd $MW_HOME/extensions/MintyDocs \ - && git checkout -q 574a593e59951eb2b81c17d69f4252d3ebadc347 \ - # MobileFrontend - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/MobileFrontend $MW_HOME/extensions/MobileFrontend \ - && cd $MW_HOME/extensions/MobileFrontend \ - && git checkout -q db7c7843189a9009dde59503e3e3d4cbcab8eaef \ - # MsUpload - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/MsUpload $MW_HOME/extensions/MsUpload \ - && cd $MW_HOME/extensions/MsUpload \ - && git checkout -q 583f3a9fdc541ef492f042be3313f4edd47205de \ - # MyVariables - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/MyVariables $MW_HOME/extensions/MyVariables \ - && cd $MW_HOME/extensions/MyVariables \ - && git checkout -q b03ca9bb5d83bbfe2db6c89cd2bdd7fc6a5e09bf \ - # NewUserMessage - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/NewUserMessage $MW_HOME/extensions/NewUserMessage \ - && cd $MW_HOME/extensions/NewUserMessage \ - && git checkout -q 0927afeedfe697984ed640ef55474aeccfffbbbb \ - # NumerAlpha - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/NumerAlpha $MW_HOME/extensions/NumerAlpha \ - && cd $MW_HOME/extensions/NumerAlpha \ - && git checkout -q ab24279b72af1c199651d4630aa198d39344785f \ - # OpenGraphMeta - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/OpenGraphMeta $MW_HOME/extensions/OpenGraphMeta \ - && cd $MW_HOME/extensions/OpenGraphMeta \ - && git checkout -q 5bbb2754497515a08562ad6cf62ed51ab9e588bd \ - # OpenIDConnect - && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/OpenIDConnect $MW_HOME/extensions/OpenIDConnect \ - && cd $MW_HOME/extensions/OpenIDConnect \ - && git checkout -q b44189a2fb29ee45330c64bcf57d6537f63b18df \ - # PageExchange (v. 0.4.1) - && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/PageExchange $MW_HOME/extensions/PageExchange \ - && cd $MW_HOME/extensions/PageExchange \ - && git checkout -q d55d5e91963fa72c6b1f6bf4304493bfe7500bd5 \ - # PageForms (v. 5.3.4) - && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/PageForms $MW_HOME/extensions/PageForms \ - && cd $MW_HOME/extensions/PageForms \ - && git checkout -q b9a4c1d8b8151611bc04bd7331d8b686e55e04af \ - # PluggableAuth - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/PluggableAuth $MW_HOME/extensions/PluggableAuth \ - && cd $MW_HOME/extensions/PluggableAuth \ - && git checkout -q d036ae0bf509ce160c4f6a1965c795d4fdae82b4 \ - # Popups - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Popups $MW_HOME/extensions/Popups \ - && cd $MW_HOME/extensions/Popups \ - && git checkout -q dccd60752353eac1063a79f81a8059b3b06b9353 \ - # RegularTooltips (needs to use master because it has no REL1_35 branch) - && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/RegularTooltips $MW_HOME/extensions/RegularTooltips \ - && cd $MW_HOME/extensions/RegularTooltips \ - && git checkout -q bc42efd6a9e7ee7571678d2f8b39c21d0d3ba1a4 \ - # RevisionSlider - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/RevisionSlider $MW_HOME/extensions/RevisionSlider \ - && cd $MW_HOME/extensions/RevisionSlider \ - && git checkout -q d1a6af207e26e220d93d16381a58055259575d3b \ - # RottenLinks - && git clone --single-branch -b master https://github.com/miraheze/RottenLinks.git $MW_HOME/extensions/RottenLinks \ - && cd $MW_HOME/extensions/RottenLinks \ - && git checkout -q 4e7e675bb26fc39b85dd62c9ad37e29d8f705a41 \ - # SandboxLink - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/SandboxLink $MW_HOME/extensions/SandboxLink \ - && cd $MW_HOME/extensions/SandboxLink \ - && git checkout -q 2d7123c29b5e61f2c7d6e81168dc6d261ff93cbd \ - # SaveSpinner - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/SaveSpinner $MW_HOME/extensions/SaveSpinner \ - && cd $MW_HOME/extensions/SaveSpinner \ - && git checkout -q 2f19bdd7c6cc48729faa4b8e9afc8953dbeaeae1 \ - # SemanticDrilldown (needs to use master because it did not include extension.json until REL1_38) - && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/SemanticDrilldown $MW_HOME/extensions/SemanticDrilldown \ - && cd $MW_HOME/extensions/SemanticDrilldown \ - && git checkout -q 873780260cf7d7999cb8434d3cf87aca4bd7368a \ - # SimpleChanges - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/SimpleChanges $MW_HOME/extensions/SimpleChanges \ - && cd $MW_HOME/extensions/SimpleChanges \ - && git checkout -q c0991c9245dc8907e59f8e4c6fb89852f0c52dde \ - # SimpleMathJax - && git clone --single-branch https://github.com/jmnote/SimpleMathJax.git $MW_HOME/extensions/SimpleMathJax \ - && cd $MW_HOME/extensions/SimpleMathJax \ - && git checkout -q ddcac9ac1616aed794576f2914ee426879194f0f \ - # SkinPerPage - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/SkinPerPage $MW_HOME/extensions/SkinPerPage \ - && cd $MW_HOME/extensions/SkinPerPage \ - && git checkout -q b929bc6e56b51a8356c04b3761c262b6a9a423e3 \ - # SmiteSpam - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/SmiteSpam $MW_HOME/extensions/SmiteSpam \ - && cd $MW_HOME/extensions/SmiteSpam \ - && git checkout -q 537809392961af21436341aaa0fb1615887dd401 \ - # SocialProfile - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/SocialProfile $MW_HOME/extensions/SocialProfile \ - && cd $MW_HOME/extensions/SocialProfile \ - && git checkout -q d34f32174c23818dbf057a5482dc6ed4781a3a25 \ - # TemplateStyles - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/TemplateStyles $MW_HOME/extensions/TemplateStyles \ - && cd $MW_HOME/extensions/TemplateStyles \ - && git checkout -q a859a0c0b742af1709d5b836737ff93ffa5a43c9 \ - # Thanks - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Thanks $MW_HOME/extensions/Thanks \ - && cd $MW_HOME/extensions/Thanks \ - && git checkout -q e28a16d38b5a4c0d32f2388aa4fcc93ec48e7b02 \ - # TimedMediaHandler - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/TimedMediaHandler $MW_HOME/extensions/TimedMediaHandler \ - && cd $MW_HOME/extensions/TimedMediaHandler \ - && git checkout -q 6d922042852cd9c6b02a406ccfcc0dae8533624b \ - # TinyMCE - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/TinyMCE $MW_HOME/extensions/TinyMCE \ - && cd $MW_HOME/extensions/TinyMCE \ - && git checkout -q 587bbb0b98044ae4904cf67f104d0cf27bd6972d \ - # UniversalLanguageSelector - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/UniversalLanguageSelector $MW_HOME/extensions/UniversalLanguageSelector \ - && cd $MW_HOME/extensions/UniversalLanguageSelector \ - && git checkout -q 25e6fd1940975c652838c3db092c55ae74d3de7b \ - # UploadWizard - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/UploadWizard $MW_HOME/extensions/UploadWizard \ - && cd $MW_HOME/extensions/UploadWizard \ - && git checkout -q c54e588bac935db78fad297602f61d47ed2162d5 \ - # UrlGetParameters - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/UrlGetParameters $MW_HOME/extensions/UrlGetParameters \ - && cd $MW_HOME/extensions/UrlGetParameters \ - && git checkout -q 163df22a566c34e0717ed8a7154f40dfb71cef4f \ - # UserFunctions (v. 2.8.0 - needs to use master because the REL1_35 version does not include extension.json) - && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/UserFunctions $MW_HOME/extensions/UserFunctions \ - && cd $MW_HOME/extensions/UserFunctions \ - && git checkout -q b6ac1ddfc3742cd88d71fa9039b06161cbc11b27 \ - # UserMerge - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/UserMerge $MW_HOME/extensions/UserMerge \ - && cd $MW_HOME/extensions/UserMerge \ - && git checkout -q 1c161b2c12c3882b4230561d1834e7c5170d9200 \ - # Variables - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Variables $MW_HOME/extensions/Variables \ - && cd $MW_HOME/extensions/Variables \ - && git checkout -q e20f4c7469bdc724ccc71767ed86deec3d1c3325 \ - # VEForAll (v. 0.4) - && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/VEForAll $MW_HOME/extensions/VEForAll \ - && cd $MW_HOME/extensions/VEForAll \ - && git checkout -q d0aec153e80b6604739aeffb60381f52d921db51 \ - # VoteNY - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/VoteNY $MW_HOME/extensions/VoteNY \ - && cd $MW_HOME/extensions/VoteNY \ - && git checkout -q b73dd009cf151a9f442361f6eb1e355817ca1e18 \ - # WhoIsWatching - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/WhoIsWatching $MW_HOME/extensions/WhoIsWatching \ - && cd $MW_HOME/extensions/WhoIsWatching \ - && git checkout -q 510e95a76fe140890ea83abf75be64ce97f7fd30 \ - # Widgets - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Widgets $MW_HOME/extensions/Widgets \ - && cd $MW_HOME/extensions/Widgets \ - && git checkout -q e9ebcb7a60e04a4b6054538032d1d2e1badf9934 \ - # WikiForum - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/WikiForum $MW_HOME/extensions/WikiForum \ - && cd $MW_HOME/extensions/WikiForum \ - && git checkout -q 9cffc82dfd761fbb7a91aa778fb6633215c47501 \ - # WikiSEO - && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/WikiSEO $MW_HOME/extensions/WikiSEO \ - && cd $MW_HOME/extensions/WikiSEO \ - && git checkout -q 2c0a40267e9e1abd087cf3fd378cc508b8562f9f \ - # WSOAuth (v. 5.0) - && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/WSOAuth $MW_HOME/extensions/WSOAuth \ - && cd $MW_HOME/extensions/WSOAuth \ - && git checkout -q 4a08a825b0a667f0a6834f58844af5fd250ceae8 - -# ReplaceText (switch to more recent commit due to bug on submodule HEAD) -RUN set -x; \ - cd $MW_HOME/extensions/ReplaceText \ - && git checkout -q 109d24b690b9096863513bdea642f88c062a3b0b - -# GTag1 -COPY _sources/extensions/GTag1.2.0.tar.gz /tmp/ -RUN set -x; \ - tar -xvf /tmp/GTag*.tar.gz -C $MW_HOME/extensions \ - && rm /tmp/GTag*.tar.gz - -# GoogleAnalyticsMetrics: Resolve composer conflicts, so placed before the composer install statement! -COPY _sources/patches/core-fix-composer-for-GoogleAnalyticsMetrics.diff /tmp/core-fix-composer-for-GoogleAnalyticsMetrics.diff -RUN set -x; \ - cd $MW_HOME \ - && git apply /tmp/core-fix-composer-for-GoogleAnalyticsMetrics.diff + && git checkout -q 86f33620f25335eb62289aa18d342ff3b980d8b8 # Composer dependencies COPY _sources/configs/composer.canasta.json $MW_HOME/composer.local.json @@ -563,57 +136,36 @@ RUN set -x; \ # Patches -# SemanticResultFormats, see https://github.com/WikiTeq/SemanticResultFormats/compare/master...WikiTeq:fix1_35 -COPY _sources/patches/semantic-result-formats.patch /tmp/semantic-result-formats.patch -RUN set -x; \ - cd $MW_HOME/extensions/SemanticResultFormats \ - && patch < /tmp/semantic-result-formats.patch - -# SWM maintenance page returns 503 (Service Unavailable) status code, PR: https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/4967 -COPY _sources/patches/smw-maintenance-503.patch /tmp/smw-maintenance-503.patch -RUN set -x; \ - cd $MW_HOME/extensions/SemanticMediaWiki \ - && patch -u -b src/SetupCheck.php -i /tmp/smw-maintenance-503.patch # TODO send to upstream, see https://wikiteq.atlassian.net/browse/MW-64 and https://wikiteq.atlassian.net/browse/MW-81 -COPY _sources/patches/skin-refreshed.patch /tmp/skin-refreshed.patch -RUN set -x; \ - cd $MW_HOME/skins/Refreshed \ - && patch -u -b includes/RefreshedTemplate.php -i /tmp/skin-refreshed.patch +#COPY _sources/patches/skin-refreshed.patch /tmp/skin-refreshed.patch +#RUN set -x; \ +# cd $MW_HOME/skins/Refreshed \ +# && patch -u -b includes/RefreshedTemplate.php -i /tmp/skin-refreshed.patch # Allow to modify headelement in the Vector skin, see https://wikiteq.atlassian.net/browse/FAM-7 -COPY _sources/patches/skin-vector-addVectorGeneratedSkinDataHook.patch /tmp/skin-vector-addVectorGeneratedSkinDataHook.patch -RUN set -x; \ - cd $MW_HOME/skins/Vector \ - && git apply /tmp/skin-vector-addVectorGeneratedSkinDataHook.patch +#COPY _sources/patches/skin-vector-addVectorGeneratedSkinDataHook.patch /tmp/skin-vector-addVectorGeneratedSkinDataHook.patch +#RUN set -x; \ +# cd $MW_HOME/skins/Vector \ +# && git apply /tmp/skin-vector-addVectorGeneratedSkinDataHook.patch -# TODO: remove for 1.36+, see https://phabricator.wikimedia.org/T281043 -COPY _sources/patches/social-profile-REL1_35.44b4f89.diff /tmp/social-profile-REL1_35.44b4f89.diff -RUN set -x; \ - cd $MW_HOME/extensions/SocialProfile \ - && git apply /tmp/social-profile-REL1_35.44b4f89.diff # WikiTeq's patch allowing to manage fields visibility site-wide -COPY _sources/patches/SocialProfile-disable-fields.patch /tmp/SocialProfile-disable-fields.patch -RUN set -x; \ - cd $MW_HOME/extensions/SocialProfile \ - && git apply /tmp/SocialProfile-disable-fields.patch +#COPY _sources/patches/SocialProfile-disable-fields.patch /tmp/SocialProfile-disable-fields.patch +#RUN set -x; \ +# cd $MW_HOME/extensions/SocialProfile \ +# && git apply /tmp/SocialProfile-disable-fields.patch -COPY _sources/patches/bootstrap-path.patch /tmp/bootstrap-path.patch -RUN set -x; \ - cd $MW_HOME/extensions/Bootstrap \ - && patch -p1 < /tmp/bootstrap-path.patch +#COPY _sources/patches/bootstrap-path.patch /tmp/bootstrap-path.patch +#RUN set -x; \ +# cd $MW_HOME/extensions/Bootstrap \ +# && patch -p1 < /tmp/bootstrap-path.patch -COPY _sources/patches/chameleon-path.patch /tmp/chameleon-path.patch -RUN set -x; \ - cd $MW_HOME/skins/chameleon \ - && git apply /tmp/chameleon-path.patch +#COPY _sources/patches/chameleon-path.patch /tmp/chameleon-path.patch +#RUN set -x; \ +# cd $MW_HOME/skins/chameleon \ +# && git apply /tmp/chameleon-path.patch -COPY _sources/patches/CommentStreams.REL1_35.core.hook.37a9e60.diff /tmp/CommentStreams.REL1_35.core.hook.37a9e60.diff -# TODO: the Hooks is added in REL1_38, remove the patch once the core is updated to 1.38 -RUN set -x; \ - cd $MW_HOME \ - && git apply /tmp/CommentStreams.REL1_35.core.hook.37a9e60.diff # Cleanup all .git leftovers RUN set -x; \ From 50af1806bcfaa8226c1ea211781b8b00014cf1d0 Mon Sep 17 00:00:00 2001 From: Jeffrey Wang Date: Sun, 30 Oct 2022 03:40:13 -0700 Subject: [PATCH 02/67] Temporarily remove excess packages --- _sources/configs/composer.canasta.json | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/_sources/configs/composer.canasta.json b/_sources/configs/composer.canasta.json index 64ce1987..99f36f4e 100644 --- a/_sources/configs/composer.canasta.json +++ b/_sources/configs/composer.canasta.json @@ -3,15 +3,7 @@ "elasticsearch/elasticsearch": "6.7.2", "mediawiki/chameleon-skin": "^3.4.1", "mediawiki/maps": "8.0.0", - "mediawiki/semantic-media-wiki": "3.2.3", - "mediawiki/semantic-result-formats": "3.2.0", - "mediawiki/semantic-breadcrumb-links": "2.0", - "mediawiki/semantic-compound-queries": "2.1.0", - "mediawiki/semantic-extra-special-properties": "2.1.0", - "mediawiki/semantic-scribunto": "2.1.0", - "mediawiki/simple-batch-upload": "1.8.2", - "mediawiki/bootstrap-components": "4.0.1", - "mediawiki/sub-page-list": "1.6.1" + "mediawiki/semantic-media-wiki": "^4.0.0" }, "extra": { "merge-plugin": { From 5f18e77070404b4a9942700d46634e722a2978cf Mon Sep 17 00:00:00 2001 From: Jeffrey Wang Date: Thu, 10 Nov 2022 11:43:20 -0600 Subject: [PATCH 03/67] Upgrade ES version --- _sources/configs/composer.canasta.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/_sources/configs/composer.canasta.json b/_sources/configs/composer.canasta.json index 99f36f4e..44bfa5c2 100644 --- a/_sources/configs/composer.canasta.json +++ b/_sources/configs/composer.canasta.json @@ -1,6 +1,6 @@ { "require": { - "elasticsearch/elasticsearch": "6.7.2", + "elasticsearch/elasticsearch": "^7.11.0", "mediawiki/chameleon-skin": "^3.4.1", "mediawiki/maps": "8.0.0", "mediawiki/semantic-media-wiki": "^4.0.0" From ceeb0b29c359ff508eb322bda08ff1a36b66a18d Mon Sep 17 00:00:00 2001 From: Jeffrey Wang Date: Thu, 10 Nov 2022 12:30:45 -0600 Subject: [PATCH 04/67] GoogleAnalyticsMetrics has dependency conflict with core MW 1.39 --- _sources/configs/composer.canasta.json | 1 - 1 file changed, 1 deletion(-) diff --git a/_sources/configs/composer.canasta.json b/_sources/configs/composer.canasta.json index 44bfa5c2..3a14e4b2 100644 --- a/_sources/configs/composer.canasta.json +++ b/_sources/configs/composer.canasta.json @@ -17,7 +17,6 @@ "extensions/AntiSpoof/composer.json", "extensions/TemplateStyles/composer.json", "extensions/Widgets/composer.json", - "extensions/GoogleAnalyticsMetrics/composer.json", "extensions/OpenIDConnect/composer.json", "extensions/WSOAuth/composer.json" ] From 93e3be6946a90d4d13cddff49594108bdc07998d Mon Sep 17 00:00:00 2001 From: Jeffrey Wang Date: Thu, 10 Nov 2022 12:32:41 -0600 Subject: [PATCH 05/67] Add upgraded extensions for 1.39 --- Dockerfile | 409 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 409 insertions(+) diff --git a/Dockerfile b/Dockerfile index 21e1ea84..f7c7ca00 100644 --- a/Dockerfile +++ b/Dockerfile @@ -117,6 +117,415 @@ RUN set -x; \ && cd $MW_HOME/skins/Refreshed \ && git checkout -q 86f33620f25335eb62289aa18d342ff3b980d8b8 +# Extensions +# The following extensions are bundled into MediaWiki and do not need to be separately installed (though in some cases +# they are modified): AbuseFilter, CategoryTree, Cite, CiteThisPage, CodeEditor, ConfirmEdit, Gadgets, ImageMap, +# InputBox, Interwiki, LocalisationUpdate, Math, MultimediaViewer, Nuke, OATHAuth, PageImages, ParserFunctions, +# PdfHandler, Poem, Renameuser, Replace Text, Scribunto, SecureLinkFixer, SpamBlacklist, SyntaxHighlight, TemplateData, +# TextExtracts, TitleBlacklist, VisualEditor, WikiEditor. +# The following extensions are downloaded via Composer and also do not need to be downloaded here: Bootstrap, +# BootstrapComponents, Maps, Semantic Breadcrumb Links, Semantic Compound Queries, Semantic Extra Special Properties, +# Semantic MediaWiki (along with all its helper library extensions, like DataValues), Semantic Result Formats, Semantic +# Scribunto, SimpleBatchUpload, SubPageList. +RUN set -x; \ + cd $MW_HOME/extensions \ + # AdminLinks + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/AdminLinks $MW_HOME/extensions/AdminLinks \ + && cd $MW_HOME/extensions/AdminLinks \ + && git checkout -q ad7805941ee29378484d1ef3595041f7d2c15913 \ + # AdvancedSearch + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/AdvancedSearch $MW_HOME/extensions/AdvancedSearch \ + && cd $MW_HOME/extensions/AdvancedSearch \ + && git checkout -q 1a44eafc93a17938333b74a37cb4deff2192e50a \ + # AJAXPoll + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/AJAXPoll $MW_HOME/extensions/AJAXPoll \ + && cd $MW_HOME/extensions/AJAXPoll \ + && git checkout -q 8429d8d4cba5be6df04e3fec17b0daabbf10cfa7 \ + # AntiSpoof + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/AntiSpoof $MW_HOME/extensions/AntiSpoof \ + && cd $MW_HOME/extensions/AntiSpoof \ + && git checkout -q 01cf89a678d5bab6610d24e07d3534356a5880cb \ + # ApprovedRevs + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/ApprovedRevs $MW_HOME/extensions/ApprovedRevs \ + && cd $MW_HOME/extensions/ApprovedRevs \ + && git checkout -q 2b95898c52751071ecc6aa07cd99dd0119cdf61c \ + # Arrays + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Arrays $MW_HOME/extensions/Arrays \ + && cd $MW_HOME/extensions/Arrays \ + && git checkout -q 338f661bf0ab377f70e029079f2c5c5b370219df \ + # BetaFeatures + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/BetaFeatures $MW_HOME/extensions/BetaFeatures \ + && cd $MW_HOME/extensions/BetaFeatures \ + && git checkout -q 09cca44341f9695446c4e9fc9e8fec3fdcb197b0 \ + # BreadCrumbs2 + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/BreadCrumbs2 $MW_HOME/extensions/BreadCrumbs2 \ + && cd $MW_HOME/extensions/BreadCrumbs2 \ + && git checkout -q d53357a6839e94800a617de4fc451b6c64d0a1c8 \ + # Cargo (v. 3.3) + && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/Cargo $MW_HOME/extensions/Cargo \ + && cd $MW_HOME/extensions/Cargo \ + && git checkout -q 9e6ae1389f0997d4e670d92a1d6b9e4b828d17cb \ + # CharInsert + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/CharInsert $MW_HOME/extensions/CharInsert \ + && cd $MW_HOME/extensions/CharInsert \ + && git checkout -q 54c0f0ca9119a3ce791fb5d53edd4ec32035a5c5 \ + # CheckUser + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/CheckUser $MW_HOME/extensions/CheckUser \ + && cd $MW_HOME/extensions/CheckUser \ + && git checkout -q 9e2b6d3e928855247700146273d8131e025de918 \ + # CirrusSearch + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/CirrusSearch $MW_HOME/extensions/CirrusSearch \ + && cd $MW_HOME/extensions/CirrusSearch \ + && git checkout -q 8296300873aaffe815800cf05c84fa04c8cbd2c0 \ + # CodeMirror + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/CodeMirror $MW_HOME/extensions/CodeMirror \ + && cd $MW_HOME/extensions/CodeMirror \ + && git checkout -q 27efed79972ca181a194d17f4a94f4192fd5a493 \ + # Collection + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Collection $MW_HOME/extensions/Collection \ + && cd $MW_HOME/extensions/Collection \ + && git checkout -q e00e70c6fcec963c8876e410e52c83c75ed60827 \ + # CommentStreams + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/CommentStreams $MW_HOME/extensions/CommentStreams \ + && cd $MW_HOME/extensions/CommentStreams \ + && git checkout -q 274bb10bc2d39fd137650dbc0dfc607c766d1aaa \ + # CommonsMetadata + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/CommonsMetadata $MW_HOME/extensions/CommonsMetadata \ + && cd $MW_HOME/extensions/CommonsMetadata \ + && git checkout -q 8ee30de3b1cabbe55c484839127493fd5fa5d076 \ + # ConfirmAccount + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/ConfirmAccount $MW_HOME/extensions/ConfirmAccount \ + && cd $MW_HOME/extensions/ConfirmAccount \ + && git checkout -q c06d5dfb43811a2dee99099476c57af2b6d762c4 \ + # ContactPage + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/ContactPage $MW_HOME/extensions/ContactPage \ + && cd $MW_HOME/extensions/ContactPage \ + && git checkout -q f509796056ae1fc597b6e3c3c268fac35bf66636 \ + # ContributionScores + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/ContributionScores $MW_HOME/extensions/ContributionScores \ + && cd $MW_HOME/extensions/ContributionScores \ + && git checkout -q e307850555ef313f623dde6e2f1d5d2a43663730 \ + # CookieWarning + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/CookieWarning $MW_HOME/extensions/CookieWarning \ + && cd $MW_HOME/extensions/CookieWarning \ + && git checkout -q bc991e93133bd69fe45e07b3d4554225decc7dae \ + # DataTransfer + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/DataTransfer $MW_HOME/extensions/DataTransfer \ + && cd $MW_HOME/extensions/DataTransfer \ + && git checkout -q 2f9f949f71f0bb7d1bd8b6b97c795b9428bb1c71 \ + # Description2 + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Description2 $MW_HOME/extensions/Description2 \ + && cd $MW_HOME/extensions/Description2 \ + && git checkout -q d2a5322a44f940de873050573e35fba4eb3063f8 \ + # Disambiguator + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Disambiguator $MW_HOME/extensions/Disambiguator \ + && cd $MW_HOME/extensions/Disambiguator \ + && git checkout -q b7e7fad5f9f3dccfb902a3cbfd3bf2b16df91871 \ + # DiscussionTools + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/DiscussionTools $MW_HOME/extensions/DiscussionTools \ + && cd $MW_HOME/extensions/DiscussionTools \ + && git checkout -q c6a73491a63e82e463b8e7e92f661cff83284b9a \ + # DismissableSiteNotice + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/DismissableSiteNotice $MW_HOME/extensions/DismissableSiteNotice \ + && cd $MW_HOME/extensions/DismissableSiteNotice \ + && git checkout -q 88129f80f077ec9e4932148056c8cfc1ed0361c7 \ + # DisplayTitle + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/DisplayTitle $MW_HOME/extensions/DisplayTitle \ + && cd $MW_HOME/extensions/DisplayTitle \ + && git checkout -q a14c406cc273c73a12957b55a27c095ad98d1795 \ + # Echo + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Echo $MW_HOME/extensions/Echo \ + && cd $MW_HOME/extensions/Echo \ + && git checkout -q fdbc2cafdc412dc60d4345511defe9ee393efecf \ + # Editcount + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Editcount $MW_HOME/extensions/Editcount \ + && cd $MW_HOME/extensions/Editcount \ + && git checkout -q 41544ffceb1356f91575dc6772a48b172751d7cc \ + # Elastica + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Elastica $MW_HOME/extensions/Elastica \ + && cd $MW_HOME/extensions/Elastica \ + && git checkout -q e4ead38b71ed4f3df8dc689fe448b749771b4ed4 \ + # EmailAuthorization + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/EmailAuthorization $MW_HOME/extensions/EmailAuthorization \ + && cd $MW_HOME/extensions/EmailAuthorization \ + && git checkout -q 2016da1b354f741d89b5dc207d4a84e11ffe9bce \ + # EmbedVideo + && git clone --single-branch -b master https://gitlab.com/hydrawiki/extensions/EmbedVideo.git $MW_HOME/extensions/EmbedVideo \ + && cd $MW_HOME/extensions/EmbedVideo \ + && git checkout -q 954af96d3744d8adc7ff6458a05e579784f2d991 \ + # EventLogging + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/EventLogging $MW_HOME/extensions/EventLogging \ + && cd $MW_HOME/extensions/EventLogging \ + && git checkout -q 2740dbcd139be279ca2a4db039739b4f796b4178 \ + # EventStreamConfig + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/EventStreamConfig $MW_HOME/extensions/EventStreamConfig \ + && cd $MW_HOME/extensions/EventStreamConfig \ + && git checkout -q 1aae8cb6c312e49f0126091a59a453cb224657f9 \ + # ExternalData (v. 3.2) + && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/ExternalData $MW_HOME/extensions/ExternalData \ + && cd $MW_HOME/extensions/ExternalData \ + && git checkout -q 5d30e60a65ca53a3fb5b39826deb2e6917892e22 \ + # FlexDiagrams + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/FlexDiagrams $MW_HOME/extensions/FlexDiagrams \ + && cd $MW_HOME/extensions/FlexDiagrams \ + && git checkout -q 550d0de3e2525d42952d7bc9d291b26455fe07ce \ + # GlobalNotice + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/GlobalNotice $MW_HOME/extensions/GlobalNotice \ + && cd $MW_HOME/extensions/GlobalNotice \ + && git checkout -q 15a40bff4641f00a5a8dda3d36795b1c659c19a7 \ + # GoogleAnalyticsMetrics + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/GoogleAnalyticsMetrics $MW_HOME/extensions/GoogleAnalyticsMetrics \ + && cd $MW_HOME/extensions/GoogleAnalyticsMetrics \ + && git checkout -q 0c131e373b145efb41d806a866cab0db34ecf18c \ + # GoogleDocCreator + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/GoogleDocCreator $MW_HOME/extensions/GoogleDocCreator \ + && cd $MW_HOME/extensions/GoogleDocCreator \ + && git checkout -q 9e53ecfa4149688a2352a7898c2a2005632e1b7d \ + # Graph + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Graph $MW_HOME/extensions/Graph \ + && cd $MW_HOME/extensions/Graph \ + && git checkout -q 9c229eafdf406c95a4a666a6b7f2a9d0d3d682e4 \ + # HeaderFooter + && git clone https://github.com/enterprisemediawiki/HeaderFooter.git $MW_HOME/extensions/HeaderFooter \ + && cd $MW_HOME/extensions/HeaderFooter \ + && git checkout -q eee7d2c1a3373c7d6b326fd460e5d4859dd22c40 \ + # HeaderTabs + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/HeaderTabs $MW_HOME/extensions/HeaderTabs \ + && cd $MW_HOME/extensions/HeaderTabs \ + && git checkout -q b3d96193f3cacef5ac2637f197f0b2822597925e \ + # HTMLTags + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/HTMLTags $MW_HOME/extensions/HTMLTags \ + && cd $MW_HOME/extensions/HTMLTags \ + && git checkout -q b8cb3131c5e76f5c037c8474fe14e51f2e877f03 \ + # LabeledSectionTransclusion + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/LabeledSectionTransclusion $MW_HOME/extensions/LabeledSectionTransclusion \ + && cd $MW_HOME/extensions/LabeledSectionTransclusion \ + && git checkout -q 187abfeaafbad35eed4254f7a7ee0638980e932a \ + # LDAPAuthentication2 + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/LDAPAuthentication2 $MW_HOME/extensions/LDAPAuthentication2 \ + && cd $MW_HOME/extensions/LDAPAuthentication2 \ + && git checkout -q 6bc584893d3157d5180e0e3ed93c3dbbc5b93056 \ + # LDAPAuthorization + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/LDAPAuthorization $MW_HOME/extensions/LDAPAuthorization \ + && cd $MW_HOME/extensions/LDAPAuthorization \ + && git checkout -q e6815d29c22f4b4eb85f868372a729ad49d7d3c8 \ + # LDAPProvider + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/LDAPProvider $MW_HOME/extensions/LDAPProvider \ + && cd $MW_HOME/extensions/LDAPProvider \ + && git checkout -q 80f8cc8156b0cd250d0dfacd9378ed0db7c2091d \ + # Lingo + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Lingo $MW_HOME/extensions/Lingo \ + && cd $MW_HOME/extensions/Lingo \ + && git checkout -q a291fa25822097a4a2aefff242a876edadb535a4 \ + # LinkSuggest + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/LinkSuggest $MW_HOME/extensions/LinkSuggest \ + && cd $MW_HOME/extensions/LinkSuggest \ + && git checkout -q 6005d191e35d1d6bed5a4e7bd1bedc5fa0030bf1 \ + # LinkTarget + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/LinkTarget $MW_HOME/extensions/LinkTarget \ + && cd $MW_HOME/extensions/LinkTarget \ + && git checkout -q e5d592dcc72a00e06604ee3f65dfb8f99977c156 \ + # Linter + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Linter $MW_HOME/extensions/Linter \ + && cd $MW_HOME/extensions/Linter \ + && git checkout -q 8bc1727955da7468f096aa5c5b5790923db43d20 \ + # LockAuthor + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/LockAuthor $MW_HOME/extensions/LockAuthor \ + && cd $MW_HOME/extensions/LockAuthor \ + && git checkout -q 4ebc4f221a0987b64740014a9380e9c3522f271d \ + # Lockdown + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Lockdown $MW_HOME/extensions/Lockdown \ + && cd $MW_HOME/extensions/Lockdown \ + && git checkout -q ffcb6e8892ad35bb731fad1dc24712a245ab86d0 \ + # LookupUser + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/LookupUser $MW_HOME/extensions/LookupUser \ + && cd $MW_HOME/extensions/LookupUser \ + && git checkout -q 5fa17d449b6bedb3e8cee5b239af6cadae31da70 \ + # Loops + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Loops $MW_HOME/extensions/Loops \ + && cd $MW_HOME/extensions/Loops \ + && git checkout -q 0eb05a81b9b53f5381eefb4f8b6959b6dcdec1d8 \ + # MagicNoCache + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/MagicNoCache $MW_HOME/extensions/MagicNoCache \ + && cd $MW_HOME/extensions/MagicNoCache \ + && git checkout -q 93534c12dac0e821c46c94b21053d274a6e557de \ + # MassMessage + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/MassMessage $MW_HOME/extensions/MassMessage \ + && cd $MW_HOME/extensions/MassMessage \ + && git checkout -q d6a86291bb975c3dc7778f370006f1145cc834bd \ + # MassMessageEmail + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/MassMessageEmail $MW_HOME/extensions/MassMessageEmail \ + && cd $MW_HOME/extensions/MassMessageEmail \ + && git checkout -q edd96f14c6d108d56bcecb18b5bb7b3355437732 \ + # MediaUploader + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/MediaUploader $MW_HOME/extensions/MediaUploader \ + && cd $MW_HOME/extensions/MediaUploader \ + && git checkout -q 1edd91c506c1c0319e7b9a3e71d639130760b1fd \ + # MintyDocs + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/MintyDocs $MW_HOME/extensions/MintyDocs \ + && cd $MW_HOME/extensions/MintyDocs \ + && git checkout -q 7d5562dd5564eeb4c3b907a9eecd84a2f7654dd1 \ + # MobileFrontend + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/MobileFrontend $MW_HOME/extensions/MobileFrontend \ + && cd $MW_HOME/extensions/MobileFrontend \ + && git checkout -q f0bed5588f76b827038fb9af73fb9677e5804077 \ + # MsUpload + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/MsUpload $MW_HOME/extensions/MsUpload \ + && cd $MW_HOME/extensions/MsUpload \ + && git checkout -q dac2376a2fac6ddf4b2038db9b4bc06092ecaa15 \ + # MyVariables + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/MyVariables $MW_HOME/extensions/MyVariables \ + && cd $MW_HOME/extensions/MyVariables \ + && git checkout -q 8b45be10c9b0a484824c55d8cc48399290384260 \ + # NewUserMessage + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/NewUserMessage $MW_HOME/extensions/NewUserMessage \ + && cd $MW_HOME/extensions/NewUserMessage \ + && git checkout -q 206f32880fa7bf70b191d33ed80b8626bca39efe \ + # NumerAlpha + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/NumerAlpha $MW_HOME/extensions/NumerAlpha \ + && cd $MW_HOME/extensions/NumerAlpha \ + && git checkout -q 93c0869735581006a3f510096738e262d49f4107 \ + # OpenGraphMeta + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/OpenGraphMeta $MW_HOME/extensions/OpenGraphMeta \ + && cd $MW_HOME/extensions/OpenGraphMeta \ + && git checkout -q d319702cd4ceda1967c233ef8e021b67b3fc355f \ + # OpenIDConnect + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/OpenIDConnect $MW_HOME/extensions/OpenIDConnect \ + && cd $MW_HOME/extensions/OpenIDConnect \ + && git checkout -q 0824f3cf3800f63e930abf0f03baf1a7c755a270 \ + # PageExchange + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/PageExchange $MW_HOME/extensions/PageExchange \ + && cd $MW_HOME/extensions/PageExchange \ + && git checkout -q 28482410564e38d2b97ab7321e99c4281c6e5877 \ + # PageForms (v. 5.5) + && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/PageForms $MW_HOME/extensions/PageForms \ + && cd $MW_HOME/extensions/PageForms \ + && git checkout -q cb25138203eafe616d4497435bd097830d640569 \ + # PluggableAuth + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/PluggableAuth $MW_HOME/extensions/PluggableAuth \ + && cd $MW_HOME/extensions/PluggableAuth \ + && git checkout -q 4be1e402e1862d165a4feb003c492ddc9525057e \ + # Popups + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Popups $MW_HOME/extensions/Popups \ + && cd $MW_HOME/extensions/Popups \ + && git checkout -q ff4d2156e1f7f4c11f7396cb0cd70d387abd8187 \ + # RegularTooltips + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/RegularTooltips $MW_HOME/extensions/RegularTooltips \ + && cd $MW_HOME/extensions/RegularTooltips \ + && git checkout -q 1af807bb6d5cfbd1e471e38bf70d6a392fb7eda2 \ + # RevisionSlider + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/RevisionSlider $MW_HOME/extensions/RevisionSlider \ + && cd $MW_HOME/extensions/RevisionSlider \ + && git checkout -q 3cae51a322a5ca0f359e83efcb5fac38e73e346e \ + # RottenLinks + && git clone --single-branch -b master https://github.com/miraheze/RottenLinks.git $MW_HOME/extensions/RottenLinks \ + && cd $MW_HOME/extensions/RottenLinks \ + && git checkout -q a96e99d0a61a42d59587a67db0720ce245a7ee46 \ + # SandboxLink + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/SandboxLink $MW_HOME/extensions/SandboxLink \ + && cd $MW_HOME/extensions/SandboxLink \ + && git checkout -q 9ab23288a010c3894c59cd5ba3096d93d57c15c5 \ + # SaveSpinner + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/SaveSpinner $MW_HOME/extensions/SaveSpinner \ + && cd $MW_HOME/extensions/SaveSpinner \ + && git checkout -q 1e819e2fff7fad6999bafe71d866c3af50836c42 \ + # SemanticDrilldown + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/SemanticDrilldown $MW_HOME/extensions/SemanticDrilldown \ + && cd $MW_HOME/extensions/SemanticDrilldown \ + && git checkout -q e960979ec5a3b1e662b3742cee7e7ef4056f9a46 \ + # SimpleChanges + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/SimpleChanges $MW_HOME/extensions/SimpleChanges \ + && cd $MW_HOME/extensions/SimpleChanges \ + && git checkout -q 5352de89dfaf043f646a44582b26f07822f02be7 \ + # SimpleMathJax + && git clone --single-branch https://github.com/jmnote/SimpleMathJax.git $MW_HOME/extensions/SimpleMathJax \ + && cd $MW_HOME/extensions/SimpleMathJax \ + && git checkout -q 3757e9b1cf235b2e2c62e7d208d52206e185b28e \ + # SkinPerPage + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/SkinPerPage $MW_HOME/extensions/SkinPerPage \ + && cd $MW_HOME/extensions/SkinPerPage \ + && git checkout -q 2793602b37c33aa4c769834feac0b88f385ccef9 \ + # SmiteSpam + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/SmiteSpam $MW_HOME/extensions/SmiteSpam \ + && cd $MW_HOME/extensions/SmiteSpam \ + && git checkout -q 268f212b7e366711d8e7b54c7faf5b750fa014ad \ + # SocialProfile + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/SocialProfile $MW_HOME/extensions/SocialProfile \ + && cd $MW_HOME/extensions/SocialProfile \ + && git checkout -q 74fcf9bead948ec0419eea10800c9331bcc1273e \ + # TemplateStyles + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/TemplateStyles $MW_HOME/extensions/TemplateStyles \ + && cd $MW_HOME/extensions/TemplateStyles \ + && git checkout -q 2a93b56e370ab8b8e020ed29c507104b56f1d11a \ + # Thanks + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Thanks $MW_HOME/extensions/Thanks \ + && cd $MW_HOME/extensions/Thanks \ + && git checkout -q 03b6a52f263604c819e69b78c157f6ef5adb053e \ + # TimedMediaHandler + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/TimedMediaHandler $MW_HOME/extensions/TimedMediaHandler \ + && cd $MW_HOME/extensions/TimedMediaHandler \ + && git checkout -q 2e64302c68e58693650e91b7869fa5aecf1aaf23 \ + # TinyMCE + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/TinyMCE $MW_HOME/extensions/TinyMCE \ + && cd $MW_HOME/extensions/TinyMCE \ + && git checkout -q 06436ec3a53c6cd53c458e4e8ab3ec8d1a23029b \ + # UniversalLanguageSelector + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/UniversalLanguageSelector $MW_HOME/extensions/UniversalLanguageSelector \ + && cd $MW_HOME/extensions/UniversalLanguageSelector \ + && git checkout -q 8216e434c38ddeba74e5ad758bfbbcc83861fa60 \ + # UploadWizard + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/UploadWizard $MW_HOME/extensions/UploadWizard \ + && cd $MW_HOME/extensions/UploadWizard \ + && git checkout -q 847413694b519c76da7196023651c8d584137d2f \ + # UrlGetParameters + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/UrlGetParameters $MW_HOME/extensions/UrlGetParameters \ + && cd $MW_HOME/extensions/UrlGetParameters \ + && git checkout -q d36f92810c762b301035ff1b4f42792ed9a1018b \ + # UserFunctions + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/UserFunctions $MW_HOME/extensions/UserFunctions \ + && cd $MW_HOME/extensions/UserFunctions \ + && git checkout -q b532b1047080c3738327ee2f3b541e563e06ca19 \ + # UserMerge + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/UserMerge $MW_HOME/extensions/UserMerge \ + && cd $MW_HOME/extensions/UserMerge \ + && git checkout -q 183bb7a8f78cbe365bec0fbd4b3ecdd4fae1a359 \ + # Variables + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Variables $MW_HOME/extensions/Variables \ + && cd $MW_HOME/extensions/Variables \ + && git checkout -q b4a9063f16a928567e3b6788cda9246c2e94797f \ + # VEForAll (v. 0.4) + && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/VEForAll $MW_HOME/extensions/VEForAll \ + && cd $MW_HOME/extensions/VEForAll \ + && git checkout -q 425454062f17f38d3ae3bcee268dcad51236a93f \ + # VoteNY + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/VoteNY $MW_HOME/extensions/VoteNY \ + && cd $MW_HOME/extensions/VoteNY \ + && git checkout -q 11c103f4b9167a8d8d5e850d8a781c6f49b249c1 \ + # WhoIsWatching + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/WhoIsWatching $MW_HOME/extensions/WhoIsWatching \ + && cd $MW_HOME/extensions/WhoIsWatching \ + && git checkout -q 836a31018e26ab7c993088c4cca31a89efec2ee5 \ + # Widgets + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Widgets $MW_HOME/extensions/Widgets \ + && cd $MW_HOME/extensions/Widgets \ + && git checkout -q 583c4f5e1829d2f78fb4a6e1f22bc9de4cf4d3a8 \ + # WikiForum + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/WikiForum $MW_HOME/extensions/WikiForum \ + && cd $MW_HOME/extensions/WikiForum \ + && git checkout -q a2685b60af86890f199a5f3b6581918369e6a571 \ + # WikiSEO + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/WikiSEO $MW_HOME/extensions/WikiSEO \ + && cd $MW_HOME/extensions/WikiSEO \ + && git checkout -q 610cffa3345333b53d4dda7b55b2012fbfcee9de \ + # WSOAuth + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/WSOAuth $MW_HOME/extensions/WSOAuth \ + && cd $MW_HOME/extensions/WSOAuth \ + && git checkout -q 3c54c4899dd63989bc3214273bf1c5807c7ac5db + +# Patch composer +RUN set -x; \ + sed -i 's="monolog/monolog": "2.2.0",="monolog/monolog": "^2.2",=g' $MW_HOME/composer.json + # Composer dependencies COPY _sources/configs/composer.canasta.json $MW_HOME/composer.local.json RUN set -x; \ From 25c51e65f4f98957ccea1bc8a913627b194a4801 Mon Sep 17 00:00:00 2001 From: Jeffrey Wang Date: Thu, 10 Nov 2022 12:33:15 -0600 Subject: [PATCH 06/67] Remove GoogleAnalyticsMetrics until Composer dependency conflict fixed --- Dockerfile | 4 ---- 1 file changed, 4 deletions(-) diff --git a/Dockerfile b/Dockerfile index f7c7ca00..dd5c7d8b 100644 --- a/Dockerfile +++ b/Dockerfile @@ -273,10 +273,6 @@ RUN set -x; \ && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/GlobalNotice $MW_HOME/extensions/GlobalNotice \ && cd $MW_HOME/extensions/GlobalNotice \ && git checkout -q 15a40bff4641f00a5a8dda3d36795b1c659c19a7 \ - # GoogleAnalyticsMetrics - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/GoogleAnalyticsMetrics $MW_HOME/extensions/GoogleAnalyticsMetrics \ - && cd $MW_HOME/extensions/GoogleAnalyticsMetrics \ - && git checkout -q 0c131e373b145efb41d806a866cab0db34ecf18c \ # GoogleDocCreator && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/GoogleDocCreator $MW_HOME/extensions/GoogleDocCreator \ && cd $MW_HOME/extensions/GoogleDocCreator \ From 507edc746b578af4514a28d2e0847e0b53f26e62 Mon Sep 17 00:00:00 2001 From: Jeffrey Wang Date: Thu, 10 Nov 2022 12:34:52 -0600 Subject: [PATCH 07/67] Bump Canasta image version to 1.3.0 --- VERSION | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/VERSION b/VERSION index 26aaba0e..f0bb29e7 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -1.2.0 +1.3.0 From 9e2d8db8b488f58711de9b70bab7b4e9f83183f9 Mon Sep 17 00:00:00 2001 From: Jeffrey Wang Date: Fri, 11 Nov 2022 17:11:33 -0600 Subject: [PATCH 08/67] Hard deprecate wfLoadExtension, wfLoadSkin in 1.3 --- _sources/canasta/CanastaUtils.php | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/_sources/canasta/CanastaUtils.php b/_sources/canasta/CanastaUtils.php index 17707c8a..22087cad 100644 --- a/_sources/canasta/CanastaUtils.php +++ b/_sources/canasta/CanastaUtils.php @@ -9,14 +9,16 @@ * @param $extName */ function cfLoadExtension( $extName ) { - echo "Warning: As of Canasta 1.2.0, this function is deprecated. Use wfLoadExtension instead."; - wfLoadExtension( $extName ); + echo "Error: As of Canasta 1.3.0, the cfLoadExtension function has been removed. Use wfLoadExtension instead.\r\n"; + echo "The following extension was loaded with cfLoadExtension, but needs to be loaded with wfLoadExtension instead: $extName"; + die(); } /** * @param $skinName */ function cfLoadSkin( $skinName ) { - echo "Warning: As of Canasta 1.2.0, this function is deprecated. Use wfLoadSkin instead."; - wfLoadSkin( $skinName ); + echo "Error: As of Canasta 1.3.0, the cfLoadSkin function has been removed. Use wfLoadSkin instead.\r\n"; + echo "The following skin was loaded with cfLoadSkin, but needs to be loaded with wfLoadSkin instead: $skinName"; + die(); } From 4b228ed1aa332d0560534c1b699b6b2371810da1 Mon Sep 17 00:00:00 2001 From: Jeffrey Wang Date: Thu, 24 Nov 2022 22:27:56 -0600 Subject: [PATCH 09/67] Bump version of GoogleAnalyticsMetrics --- Dockerfile | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Dockerfile b/Dockerfile index dd5c7d8b..3379add3 100644 --- a/Dockerfile +++ b/Dockerfile @@ -273,6 +273,10 @@ RUN set -x; \ && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/GlobalNotice $MW_HOME/extensions/GlobalNotice \ && cd $MW_HOME/extensions/GlobalNotice \ && git checkout -q 15a40bff4641f00a5a8dda3d36795b1c659c19a7 \ + # GoogleAnalyticsMetrics + && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/GoogleAnalyticsMetrics $MW_HOME/extensions/GoogleAnalyticsMetrics \ + && cd $MW_HOME/extensions/GoogleAnalyticsMetrics \ + && git checkout -q 82a08cc63ec58698f144be7c2fb1a6f861cb57bd \ # GoogleDocCreator && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/GoogleDocCreator $MW_HOME/extensions/GoogleDocCreator \ && cd $MW_HOME/extensions/GoogleDocCreator \ From 92499f7e71a1ee111574a7b4e84132c08414e840 Mon Sep 17 00:00:00 2001 From: Pavel Astakhov Date: Fri, 25 Nov 2022 22:33:31 +0600 Subject: [PATCH 10/67] Fix prepare_extensions_skins_symlinks() in run-apache.sh We should prepate the symlinks at the firts step (at least before we call get_mediawiki_variable() function, in other case get_mediawiki_variable does not work (throws errors) because extensions and skinks don't exist (the symlynks were not created) P.S. I don't like this idea with symlynks very much. --- _sources/scripts/run-apache.sh | 80 +++++++++++++++++----------------- 1 file changed, 40 insertions(+), 40 deletions(-) diff --git a/_sources/scripts/run-apache.sh b/_sources/scripts/run-apache.sh index 8e07d775..59288e34 100755 --- a/_sources/scripts/run-apache.sh +++ b/_sources/scripts/run-apache.sh @@ -48,6 +48,46 @@ dir_is_writable() { return 1 } +prepare_extensions_skins_symlinks() { + echo "Symlinking bundled extensions..." + for bundled_extension_path in $(find $MW_HOME/canasta-extensions/ -maxdepth 1 -mindepth 1 -type d) + do + bundled_extension_id=$(basename $bundled_extension_path) + ln -s $MW_HOME/canasta-extensions/$bundled_extension_id/ $MW_HOME/extensions/$bundled_extension_id + done + echo "Symlinking bundled skins..." + for bundled_skin_path in $(find $MW_HOME/canasta-skins/ -maxdepth 1 -mindepth 1 -type d) + do + bundled_skin_id=$(basename $bundled_skin_path) + ln -s $MW_HOME/canasta-skins/$bundled_skin_id/ $MW_HOME/skins/$bundled_skin_id + done + echo "Symlinking user extensions and overwriting any redundant bundled extensions..." + for user_extension_path in $(find $MW_HOME/user-extensions/ -maxdepth 1 -mindepth 1 -type d) + do + user_extension_id=$(basename $user_extension_path) + extension_symlink_path="$MW_HOME/extensions/$user_extension_id" + if [[ -e "$extension_symlink_path" ]] + then + rm "$extension_symlink_path" + fi + ln -s $MW_HOME/user-extensions/$user_extension_id/ $MW_HOME/extensions/$user_extension_id + done + echo "Symlinking user skins and overwriting any redundant bundled skins..." + for user_skin_path in $(find $MW_HOME/user-skins/ -maxdepth 1 -mindepth 1 -type d) + do + user_skin_id=$(basename $user_skin_path) + skin_symlink_path="$MW_HOME/skins/$user_skin_id" + if [[ -e "$skin_symlink_path" ]] + then + rm "$skin_symlink_path" + fi + ln -s $MW_HOME/user-skins/$user_skin_id/ $MW_HOME/skins/$user_skin_id + done +} + +# Symlink all extensions and skins (both bundled and user) +prepare_extensions_skins_symlinks + # Soft sync contents from $MW_ORIGIN_FILES directory to $MW_VOLUME # The goal of this operation is to copy over all the files generated # by the image to bind-mount points on host which are bind to @@ -171,52 +211,12 @@ check_mount_points () { fi } -prepare_extensions_skins_symlinks() { - echo "Symlinking bundled extensions..." - for bundled_extension_path in $(find $MW_HOME/canasta-extensions/ -maxdepth 1 -mindepth 1 -type d) - do - bundled_extension_id=$(basename $bundled_extension_path) - ln -s $MW_HOME/canasta-extensions/$bundled_extension_id/ $MW_HOME/extensions/$bundled_extension_id - done - echo "Symlinking bundled skins..." - for bundled_skin_path in $(find $MW_HOME/canasta-skins/ -maxdepth 1 -mindepth 1 -type d) - do - bundled_skin_id=$(basename $bundled_skin_path) - ln -s $MW_HOME/canasta-skins/$bundled_skin_id/ $MW_HOME/skins/$bundled_skin_id - done - echo "Symlinking user extensions and overwriting any redundant bundled extensions..." - for user_extension_path in $(find $MW_HOME/user-extensions/ -maxdepth 1 -mindepth 1 -type d) - do - user_extension_id=$(basename $user_extension_path) - extension_symlink_path="$MW_HOME/extensions/$user_extension_id" - if [[ -e "$extension_symlink_path" ]] - then - rm "$extension_symlink_path" - fi - ln -s $MW_HOME/user-extensions/$user_extension_id/ $MW_HOME/extensions/$user_extension_id - done - echo "Symlinking user skins and overwriting any redundant bundled skins..." - for user_skin_path in $(find $MW_HOME/user-skins/ -maxdepth 1 -mindepth 1 -type d) - do - user_skin_id=$(basename $user_skin_path) - skin_symlink_path="$MW_HOME/skins/$user_skin_id" - if [[ -e "$skin_symlink_path" ]] - then - rm "$skin_symlink_path" - fi - ln -s $MW_HOME/user-skins/$user_skin_id/ $MW_HOME/skins/$user_skin_id - done -} - # Wait db waitdatabase # Check for `user-` prefixed mounts and bow out if not found check_mount_points -# Symlink all extensions and skins (both bundled and user) -prepare_extensions_skins_symlinks - sleep 1 cd "$MW_HOME" || exit From c1fe11d6cdf979ca6eb8731d28cc38b8bbbff79b Mon Sep 17 00:00:00 2001 From: Pavel Astakhov Date: Sat, 26 Nov 2022 00:38:21 +0600 Subject: [PATCH 11/67] Version 1.2.1 --- VERSION | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/VERSION b/VERSION index 26aaba0e..6085e946 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -1.2.0 +1.2.1 From 771a104a2b07c2f0ec48f00991fbe35b455bf30e Mon Sep 17 00:00:00 2001 From: Jeffrey Wang Date: Thu, 1 Dec 2022 00:16:08 -0600 Subject: [PATCH 12/67] Use released version of 1.39 --- Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 3379add3..be0dac07 100644 --- a/Dockerfile +++ b/Dockerfile @@ -4,7 +4,7 @@ LABEL maintainers="" LABEL org.opencontainers.image.source=https://github.com/CanastaWiki/Canasta ENV MW_VERSION=REL1_39 \ - MW_CORE_VERSION=1.39.0-rc.1 \ + MW_CORE_VERSION=1.39.0 \ WWW_ROOT=/var/www/mediawiki \ MW_HOME=/var/www/mediawiki/w \ MW_ORIGIN_FILES=/mw_origin_files \ From b3f24318673e8c1b59dc56653d5233211318c9eb Mon Sep 17 00:00:00 2001 From: Yaron Koren Date: Tue, 6 Dec 2022 22:45:57 -0500 Subject: [PATCH 13/67] Delete pageforms-xss-cherry-picked.patch (#169) Patch is no longer used. --- .../patches/pageforms-xss-cherry-picked.patch | 118 ------------------ 1 file changed, 118 deletions(-) delete mode 100644 _sources/patches/pageforms-xss-cherry-picked.patch diff --git a/_sources/patches/pageforms-xss-cherry-picked.patch b/_sources/patches/pageforms-xss-cherry-picked.patch deleted file mode 100644 index ec46f893..00000000 --- a/_sources/patches/pageforms-xss-cherry-picked.patch +++ /dev/null @@ -1,118 +0,0 @@ -From 5685e10ffe6d5c6c7bd3f3181faaa14e505c31e3 Mon Sep 17 00:00:00 2001 -From: Yaron Koren -Date: Wed, 20 Jan 2021 16:40:33 +0000 -Subject: [PATCH] Improve HTML-escaping in combobox and tokens inputs - -Bug: T259433 -Change-Id: I20b63bd38779d2ccbe2d86f9879df85ca3b685f6 ---- - libs/ext.pf.select2.base.js | 47 +++++++++++++++++++++++++++++---- - libs/ext.pf.select2.combobox.js | 5 +++- - libs/ext.pf.select2.tokens.js | 4 ++- - 3 files changed, 49 insertions(+), 7 deletions(-) - -diff --git a/libs/ext.pf.select2.base.js b/libs/ext.pf.select2.base.js -index 8867a8b3..dfcd6edb 100644 ---- a/libs/ext.pf.select2.base.js -+++ b/libs/ext.pf.select2.base.js -@@ -225,6 +225,43 @@ - autocomplete_opts.autocompletesettings = $(input_id).attr( "autocompletesettings" ); - return autocomplete_opts; - }, -+ -+ /** -+ * Escape out any HTML, and then add our own HTML to display -+ * the correct bolding. -+ * The first part of this function is directly copied from -+ * Utils::escapeMarkup() in the Select2 code. @TODO: figure out -+ * how to just call that code directly. -+ */ -+ escapeMarkupAndAddHTML: function( markup ) { -+ var replaceMap = { -+ '\\': '\', -+ '&': '&', -+ '<': '<', -+ '>': '>', -+ '"': '"', -+ '\'': ''', -+ '/': '/' -+ }; -+ -+ // Do not try to escape the markup if it's not a string -+ if (typeof markup !== 'string') { -+ return markup; -+ } -+ -+ var escapedMarkup = String(markup).replace(/[&<>"'\/\\]/g, function (match) { -+ return replaceMap[match]; -+ }) -+ -+ var boldStart = String.fromCharCode(1); -+ var boldEnd = String.fromCharCode(2); -+ return '' + -+ escapedMarkup -+ .replace(boldStart, '') -+ .replace(boldEnd, '') + -+ ''; -+ }, -+ - /* - * Refreshes the field if there is a change - * in the autocomplete vlaues -@@ -271,11 +308,11 @@ - } - - if ( start !== -1 ) { -- markup = (text.substr(0, start) + -- '' + -- text.substr(start,term.length) + -- '' + -- text.substr(start + term.length, text.length)+''); -+ var boldStart = String.fromCharCode(1); -+ var boldEnd = String.fromCharCode(2); -+ markup = text.substr(0, start) + boldStart + -+ text.substr(start,term.length) + boldEnd + -+ text.substr(start + term.length, text.length); - } else { - markup = (text); - } -diff --git a/libs/ext.pf.select2.combobox.js b/libs/ext.pf.select2.combobox.js -index 0508c844..cbc0608d 100644 ---- a/libs/ext.pf.select2.combobox.js -+++ b/libs/ext.pf.select2.combobox.js -@@ -39,13 +39,16 @@ - * - */ - combobox_proto.setOptions = function() { -+ var self = this; - var input_id = this.id; - var opts = {}; - opts.language = {}; - input_id = "#" + input_id; - var input_tagname = $(input_id).prop( "tagName" ); - var autocomplete_opts = this.getAutocompleteOpts(); -- opts.escapeMarkup = function (m) { return m; }; -+ opts.escapeMarkup = function (m) { -+ return self.escapeMarkupAndAddHTML(m); -+ }; - if ( autocomplete_opts.autocompletedatatype !== undefined ) { - opts.ajax = this.getAjaxOpts(); - opts.minimumInputLength = 1; -diff --git a/libs/ext.pf.select2.tokens.js b/libs/ext.pf.select2.tokens.js -index c7182b51..feda3ea7 100644 ---- a/libs/ext.pf.select2.tokens.js -+++ b/libs/ext.pf.select2.tokens.js -@@ -171,7 +171,9 @@ - input_id = "#" + input_id; - var input_tagname = $(input_id).prop( "tagName" ); - var autocomplete_opts = this.getAutocompleteOpts(); -- opts.escapeMarkup = function (m) { return m; }; -+ opts.escapeMarkup = function (m) { -+ return self.escapeMarkupAndAddHTML(m); -+ }; - if ( autocomplete_opts.autocompletedatatype !== undefined ) { - opts.ajax = this.getAjaxOpts(); - opts.minimumInputLength = 1; --- -2.30.1 (Apple Git-130) - From 8d21b4e7825d5a11cc136d329c36969ccdccff5e Mon Sep 17 00:00:00 2001 From: Yaron Koren Date: Tue, 6 Dec 2022 22:46:19 -0500 Subject: [PATCH 14/67] Delete core-fix-for-curl-a2f60bb.diff (#170) Patch is no longer used. --- .../patches/core-fix-for-curl-a2f60bb.diff | 31 ------------------- 1 file changed, 31 deletions(-) delete mode 100644 _sources/patches/core-fix-for-curl-a2f60bb.diff diff --git a/_sources/patches/core-fix-for-curl-a2f60bb.diff b/_sources/patches/core-fix-for-curl-a2f60bb.diff deleted file mode 100644 index 5d6e772d..00000000 --- a/_sources/patches/core-fix-for-curl-a2f60bb.diff +++ /dev/null @@ -1,31 +0,0 @@ -From a2f60bbbc4d6e2d53f498140374462e164962e96 Mon Sep 17 00:00:00 2001 -From: Reedy -Date: Wed, 02 Dec 2020 01:05:54 +0000 -Subject: [PATCH] Make use of CURLMOPT_MAX_HOST_CONNECTIONS conditional on having curl >= 7.30.0 - -Bug: T264986 -Change-Id: I0a91eaf456d855b3f064bf5e4202bab1ced4a94c -(cherry picked from commit 898ba5f607afa9d1fb410e22768efd89379f389c) ---- - -diff --git a/includes/libs/http/MultiHttpClient.php b/includes/libs/http/MultiHttpClient.php -index 1a73361..3962eec 100644 ---- a/includes/libs/http/MultiHttpClient.php -+++ b/includes/libs/http/MultiHttpClient.php -@@ -443,9 +443,13 @@ - $this->cmh = $cmh; - } - -- // Limit the number of in-flight requests for any given host -- $maxHostConns = $opts['maxConnsPerHost'] ?? $this->maxConnsPerHost; -- curl_multi_setopt( $this->cmh, CURLMOPT_MAX_HOST_CONNECTIONS, (int)$maxHostConns ); -+ // CURLMOPT_MAX_HOST_CONNECTIONS is available since PHP 7.0.7 and cURL 7.30.0 -+ if ( version_compare( curl_version()['version'], '7.30.0', '>=' ) ) { -+ // Limit the number of in-flight requests for any given host -+ $maxHostConns = $opts['maxConnsPerHost'] ?? $this->maxConnsPerHost; -+ curl_multi_setopt( $this->cmh, CURLMOPT_MAX_HOST_CONNECTIONS, (int)$maxHostConns ); -+ } -+ - // Configure when to multiplex multiple requests onto single TCP handles - $pipelining = $opts['usePipelining'] ?? $this->usePipelining; - curl_multi_setopt( $this->cmh, CURLMOPT_PIPELINING, $pipelining ? 3 : 0 ); From 53d60638a0a07aa6ea49fe9b20ad4063524d15ea Mon Sep 17 00:00:00 2001 From: Yaron Koren Date: Wed, 7 Dec 2022 14:18:35 -0500 Subject: [PATCH 15/67] Remove patches that are unnecessary for MW 1.39 (#168) * Remove patches that are unnecessary for MW 1.39 These four patches are unnecessary for the latest code: the patches to CommentStreams, Semantic MediaWiki and Semantic Result Formats were all added already to their respective extensions, while the patch for core MediaWiki, done in order to get the GoogleAnalyticsMetrics extension working, is no longer necessary due to a recent fix to GoogleAnalyticsMetrics. * Delete CommentStreams.REL1_35.core.hook.37a9e60.diff * Delete core-fix-composer-for-GoogleAnalyticsMetrics.diff * Delete core-fix-for-curl-a2f60bb.diff * Delete smw-maintenance-503.patch * Delete semantic-result-formats.patch --- ...mentStreams.REL1_35.core.hook.37a9e60.diff | 140 ------------------ ...x-composer-for-GoogleAnalyticsMetrics.diff | 12 -- .../patches/semantic-result-formats.patch | 126 ---------------- _sources/patches/smw-maintenance-503.patch | 12 -- 4 files changed, 290 deletions(-) delete mode 100644 _sources/patches/CommentStreams.REL1_35.core.hook.37a9e60.diff delete mode 100644 _sources/patches/core-fix-composer-for-GoogleAnalyticsMetrics.diff delete mode 100644 _sources/patches/semantic-result-formats.patch delete mode 100644 _sources/patches/smw-maintenance-503.patch diff --git a/_sources/patches/CommentStreams.REL1_35.core.hook.37a9e60.diff b/_sources/patches/CommentStreams.REL1_35.core.hook.37a9e60.diff deleted file mode 100644 index b997993b..00000000 --- a/_sources/patches/CommentStreams.REL1_35.core.hook.37a9e60.diff +++ /dev/null @@ -1,140 +0,0 @@ -diff --git a/autoload.php b/autoload.php -index 805ebb2..507225b 100644 ---- a/autoload.php -+++ b/autoload.php -@@ -1025,6 +1025,7 @@ $wgAutoloadLocalClasses = [ - 'MediaWiki\\Hook\\SpecialContributionsBeforeMainOutputHook' => __DIR__ . '/includes/specials/Hook/SpecialContributionsBeforeMainOutputHook.php', - 'MediaWiki\\Hook\\SpecialContributions__formatRow__flagsHook' => __DIR__ . '/includes/specials/Hook/SpecialContributions__formatRow__flagsHook.php', - 'MediaWiki\\Hook\\SpecialContributions__getForm__filtersHook' => __DIR__ . '/includes/specials/Hook/SpecialContributions__getForm__filtersHook.php', -+ 'MediaWiki\\Hook\\SpecialExportGetExtraPagesHook' => __DIR__ . '/includes/specials/Hook/SpecialExportGetExtraPagesHook.php', - 'MediaWiki\\Hook\\SpecialListusersDefaultQueryHook' => __DIR__ . '/includes/specials/Hook/SpecialListusersDefaultQueryHook.php', - 'MediaWiki\\Hook\\SpecialListusersFormatRowHook' => __DIR__ . '/includes/specials/Hook/SpecialListusersFormatRowHook.php', - 'MediaWiki\\Hook\\SpecialListusersHeaderFormHook' => __DIR__ . '/includes/specials/Hook/SpecialListusersHeaderFormHook.php', -diff --git a/includes/HookContainer/HookRunner.php b/includes/HookContainer/HookRunner.php -index f77b9c2..32b5e44 100644 ---- a/includes/HookContainer/HookRunner.php -+++ b/includes/HookContainer/HookRunner.php -@@ -332,6 +332,7 @@ class HookRunner implements - \MediaWiki\Hook\SpecialBlockModifyFormFieldsHook, - \MediaWiki\Hook\SpecialContributionsBeforeMainOutputHook, - \MediaWiki\Hook\SpecialContributions__formatRow__flagsHook, -+ \MediaWiki\Hook\SpecialExportGetExtraPagesHook, - \MediaWiki\Hook\SpecialContributions__getForm__filtersHook, - \MediaWiki\Hook\SpecialListusersDefaultQueryHook, - \MediaWiki\Hook\SpecialListusersFormatRowHook, -@@ -3666,6 +3667,13 @@ class HookRunner implements - ); - } - -+ public function onSpecialExportGetExtraPages( $inputPages, &$extraPages ) { -+ return $this->container->run( -+ 'SpecialExportGetExtraPages', -+ [ $inputPages, &$extraPages ] -+ ); -+ } -+ - public function onSpecialListusersDefaultQuery( $pager, &$query ) { - return $this->container->run( - 'SpecialListusersDefaultQuery', -diff --git a/includes/specialpage/SpecialPageFactory.php b/includes/specialpage/SpecialPageFactory.php -index 59ecef8..6d6305c 100644 ---- a/includes/specialpage/SpecialPageFactory.php -+++ b/includes/specialpage/SpecialPageFactory.php -@@ -187,7 +187,12 @@ class SpecialPageFactory { - - // Page tools - 'ComparePages' => \SpecialComparePages::class, -- 'Export' => \SpecialExport::class, -+ 'Export' => [ -+ 'class' => \SpecialExport::class, -+ 'services' => [ -+ 'TitleFormatter' -+ ] -+ ], - 'Import' => \SpecialImport::class, - 'Undelete' => \SpecialUndelete::class, - 'Whatlinkshere' => \SpecialWhatLinksHere::class, -diff --git a/includes/specials/Hook/SpecialExportGetExtraPagesHook.php b/includes/specials/Hook/SpecialExportGetExtraPagesHook.php -new file mode 100644 -index 0000000..3536ab2 ---- /dev/null -+++ b/includes/specials/Hook/SpecialExportGetExtraPagesHook.php -@@ -0,0 +1,25 @@ -+titleFormatter = $titleFormatter; - } - - public function execute( $par ) { -@@ -365,6 +374,7 @@ class SpecialExport extends SpecialPage { - if ( $this->templates ) { - $pageSet = $this->getTemplates( $inputPages, $pageSet ); - } -+ $pageSet = $this->getExtraPages( $inputPages, $pageSet ); - $linkDepth = $this->pageLinkDepth; - if ( $linkDepth ) { - $pageSet = $this->getPageLinks( $inputPages, $pageSet, $linkDepth ); -@@ -478,6 +488,21 @@ class SpecialExport extends SpecialPage { - ); - } - -+ /** -+ * Add extra pages to the list of pages to export. -+ * @param string[] $inputPages List of page titles to export -+ * @param bool[] $pageSet Initial associative array indexed by string page titles -+ * @return bool[] Associative array indexed by string page titles including extra pages -+ */ -+ private function getExtraPages( $inputPages, $pageSet ) { -+ $extraPages = []; -+ $this->getHookRunner()->onSpecialExportGetExtraPages( $inputPages, $extraPages ); -+ foreach ( $extraPages as $extraPage ) { -+ $pageSet[$this->titleFormatter->getPrefixedText( $extraPage )] = true; -+ } -+ return $pageSet; -+ } -+ - /** - * Validate link depth setting, if available. - * @param int $depth diff --git a/_sources/patches/core-fix-composer-for-GoogleAnalyticsMetrics.diff b/_sources/patches/core-fix-composer-for-GoogleAnalyticsMetrics.diff deleted file mode 100644 index 9b6d7afd..00000000 --- a/_sources/patches/core-fix-composer-for-GoogleAnalyticsMetrics.diff +++ /dev/null @@ -1,12 +0,0 @@ -diff --git a/composer.json b/composer.json -index f663f26239..5e5aaf8f2d 100644 ---- a/composer.json -+++ b/composer.json -@@ -80,7 +80,6 @@ - "justinrainbow/json-schema": "~5.2", - "mediawiki/mediawiki-codesniffer": "38.0.0", - "mediawiki/mediawiki-phan-config": "0.10.6", -- "monolog/monolog": "~2.2.0", - "nikic/php-parser": "4.4.0", - "nmred/kafka-php": "0.1.5", - "php-parallel-lint/php-console-highlighter": "0.5", diff --git a/_sources/patches/semantic-result-formats.patch b/_sources/patches/semantic-result-formats.patch deleted file mode 100644 index 4d47f281..00000000 --- a/_sources/patches/semantic-result-formats.patch +++ /dev/null @@ -1,126 +0,0 @@ -From 5b1242138fc4b4870216e64b5e761284d9d9bfd2 Mon Sep 17 00:00:00 2001 -From: Pavel Astakhov -Date: Sun, 31 Jan 2021 17:21:03 +0600 -Subject: [PATCH 1/2] Remove jquery.ui.core from dependencies in Resources.php - ---- - Resources.php | 5 ----- - 1 file changed, 5 deletions(-) - -diff --git a/Resources.php b/Resources.php -index 26871a9e..caacd6f5 100644 ---- a/Resources.php -+++ b/Resources.php -@@ -64,7 +64,6 @@ - 'scripts' => 'resources/jquery/multiselect/jquery.multiselect.js', - 'styles' => 'resources/jquery/multiselect/jquery.multiselect.css', - 'dependencies' => [ -- 'jquery.ui.core', - 'jquery.ui.widget' - ] - ], -@@ -89,7 +88,6 @@ - ], - 'styles' => 'resources/jquery/jqgrid/ui.jqgrid.css', - 'dependencies' => [ -- 'jquery.ui.core', - 'ext.jquery.migration.browser' - ] - ], -@@ -172,7 +170,6 @@ - ], - 'dependencies' => [ - 'ext.srf', -- 'jquery.ui.core', - 'jquery.ui.widget', - 'jquery.ui.button', - 'jquery.ui.slider', -@@ -739,7 +736,6 @@ - 'calendar/resources/ext.srf.widgets.calendarlegend.js', - ], - 'dependencies' => [ -- 'jquery.ui.core', - 'jquery.ui.widget', - 'jquery.ui.datepicker', - 'jquery.ui.slider', -@@ -951,7 +947,6 @@ - 'dependencies' => [ - 'jquery.dataTables', - 'jquery.dataTables.extras', -- 'jquery.ui.core', - 'jquery.ui.widget', - 'jquery.ui.button', - 'ext.smw.dataItem', - -From b9923ec13c7834b5b141b3e7427aa8c311d987cb Mon Sep 17 00:00:00 2001 -From: Pavel Astakhov -Date: Sun, 31 Jan 2021 21:11:39 +0600 -Subject: [PATCH 2/2] Replace jquery.ui.* modules with jquery.ui in - Resources.php - ---- - Resources.php | 16 ++++++---------- - 1 file changed, 6 insertions(+), 10 deletions(-) - -diff --git a/Resources.php b/Resources.php -index caacd6f5..5f033b66 100644 ---- a/Resources.php -+++ b/Resources.php -@@ -64,7 +64,7 @@ - 'scripts' => 'resources/jquery/multiselect/jquery.multiselect.js', - 'styles' => 'resources/jquery/multiselect/jquery.multiselect.css', - 'dependencies' => [ -- 'jquery.ui.widget' -+ 'jquery.ui', - ] - ], - -@@ -88,6 +88,7 @@ - ], - 'styles' => 'resources/jquery/jqgrid/ui.jqgrid.css', - 'dependencies' => [ -+ 'jquery.ui', - 'ext.jquery.migration.browser' - ] - ], -@@ -170,9 +171,7 @@ - ], - 'dependencies' => [ - 'ext.srf', -- 'jquery.ui.widget', -- 'jquery.ui.button', -- 'jquery.ui.slider', -+ 'jquery.ui', - 'ext.jquery.multiselect' - ], - 'messages' => [ -@@ -185,7 +184,7 @@ - 'scripts' => 'resources/ext.srf.util.grid.js', - 'styles' => 'resources/ext.srf.util.grid.css', - 'dependencies' => [ -- 'jquery.ui.tabs', -+ 'jquery.ui', - 'ext.srf.util', - 'ext.jquery.jqgrid', - ], -@@ -736,9 +735,7 @@ - 'calendar/resources/ext.srf.widgets.calendarlegend.js', - ], - 'dependencies' => [ -- 'jquery.ui.widget', -- 'jquery.ui.datepicker', -- 'jquery.ui.slider', -+ 'jquery.ui', - 'ext.smw.tooltip', - 'ext.srf.util', - 'ext.srf.api', -@@ -947,8 +944,7 @@ - 'dependencies' => [ - 'jquery.dataTables', - 'jquery.dataTables.extras', -- 'jquery.ui.widget', -- 'jquery.ui.button', -+ 'jquery.ui', - 'ext.smw.dataItem', - 'ext.smw.api', - 'ext.srf.api', diff --git a/_sources/patches/smw-maintenance-503.patch b/_sources/patches/smw-maintenance-503.patch deleted file mode 100644 index def5c568..00000000 --- a/_sources/patches/smw-maintenance-503.patch +++ /dev/null @@ -1,12 +0,0 @@ ---- src/SetupCheck.php.20210404 2021-03-29 22:40:46.000000000 +0000 -+++ src/SetupCheck.php 2021-04-04 11:55:33.314354724 +0000 -@@ -343,6 +343,9 @@ - $this->header( 'Content-Length: ' . strlen( $content ) ); - $this->header( 'Cache-control: none' ); - $this->header( 'Pragma: no-cache' ); -+ $this->header( 'HTTP/1.1 503 Service Temporarily Unavailable' ); -+ $this->header( 'Status: 503 Service Temporarily Unavailable' ); -+ $this->header( 'Retry-After: 10' ); // 10 seconds - } else { - $content = $error['title'] . "\n\n" . $error['content']; - $content = str_replace( From fefdd0fde0827822a5dec0263b206c22081d1b7f Mon Sep 17 00:00:00 2001 From: Yaron Koren Date: Wed, 7 Dec 2022 15:07:15 -0500 Subject: [PATCH 16/67] Update ApprovedRevs, Cargo, PageForms, VEForAll to the 1.39 version (#163) * Update ApprovedRevs, Cargo, PageForms, VEForAll to the version that supports MW 1.39 * Update Dockerfile --- Dockerfile | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/Dockerfile b/Dockerfile index be0dac07..64732900 100644 --- a/Dockerfile +++ b/Dockerfile @@ -145,10 +145,10 @@ RUN set -x; \ && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/AntiSpoof $MW_HOME/extensions/AntiSpoof \ && cd $MW_HOME/extensions/AntiSpoof \ && git checkout -q 01cf89a678d5bab6610d24e07d3534356a5880cb \ - # ApprovedRevs - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/ApprovedRevs $MW_HOME/extensions/ApprovedRevs \ + # ApprovedRevs (v. 1.8) + && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/ApprovedRevs $MW_HOME/extensions/ApprovedRevs \ && cd $MW_HOME/extensions/ApprovedRevs \ - && git checkout -q 2b95898c52751071ecc6aa07cd99dd0119cdf61c \ + && git checkout -q 6e9c957f2f7951f19054ecae8745e55c0425941f \ # Arrays && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Arrays $MW_HOME/extensions/Arrays \ && cd $MW_HOME/extensions/Arrays \ @@ -161,10 +161,10 @@ RUN set -x; \ && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/BreadCrumbs2 $MW_HOME/extensions/BreadCrumbs2 \ && cd $MW_HOME/extensions/BreadCrumbs2 \ && git checkout -q d53357a6839e94800a617de4fc451b6c64d0a1c8 \ - # Cargo (v. 3.3) + # Cargo (v. 3.3.1) && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/Cargo $MW_HOME/extensions/Cargo \ && cd $MW_HOME/extensions/Cargo \ - && git checkout -q 9e6ae1389f0997d4e670d92a1d6b9e4b828d17cb \ + && git checkout -q dac6b0da0e3cb5a4226601ebccf1689dbaa6bec7 \ # CharInsert && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/CharInsert $MW_HOME/extensions/CharInsert \ && cd $MW_HOME/extensions/CharInsert \ @@ -397,10 +397,10 @@ RUN set -x; \ && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/PageExchange $MW_HOME/extensions/PageExchange \ && cd $MW_HOME/extensions/PageExchange \ && git checkout -q 28482410564e38d2b97ab7321e99c4281c6e5877 \ - # PageForms (v. 5.5) + # PageForms (v. 5.5.1) && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/PageForms $MW_HOME/extensions/PageForms \ && cd $MW_HOME/extensions/PageForms \ - && git checkout -q cb25138203eafe616d4497435bd097830d640569 \ + && git checkout -q 74ebc5de5d1b515aeb59c848c3a9e3425da13114 \ # PluggableAuth && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/PluggableAuth $MW_HOME/extensions/PluggableAuth \ && cd $MW_HOME/extensions/PluggableAuth \ @@ -493,10 +493,10 @@ RUN set -x; \ && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Variables $MW_HOME/extensions/Variables \ && cd $MW_HOME/extensions/Variables \ && git checkout -q b4a9063f16a928567e3b6788cda9246c2e94797f \ - # VEForAll (v. 0.4) + # VEForAll (v. 0.4.1) && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/VEForAll $MW_HOME/extensions/VEForAll \ && cd $MW_HOME/extensions/VEForAll \ - && git checkout -q 425454062f17f38d3ae3bcee268dcad51236a93f \ + && git checkout -q 2f1f08eca7fbf61198e5f4ccf2d627a6c9ef7b64 \ # VoteNY && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/VoteNY $MW_HOME/extensions/VoteNY \ && cd $MW_HOME/extensions/VoteNY \ From 2712ff7d63bbcaf14c0a69c06ea46791ee4917f8 Mon Sep 17 00:00:00 2001 From: Vedmaka Date: Fri, 9 Dec 2022 19:42:16 +0400 Subject: [PATCH 17/67] Removes unnecessary patch for Refreshed skin (#175) --- Dockerfile | 6 ------ _sources/patches/skin-refreshed.patch | 11 ----------- 2 files changed, 17 deletions(-) delete mode 100644 _sources/patches/skin-refreshed.patch diff --git a/Dockerfile b/Dockerfile index 6b74dc07..aa6bea4a 100644 --- a/Dockerfile +++ b/Dockerfile @@ -575,12 +575,6 @@ RUN set -x; \ cd $MW_HOME/extensions/SemanticMediaWiki \ && patch -u -b src/SetupCheck.php -i /tmp/smw-maintenance-503.patch -# TODO send to upstream, see https://wikiteq.atlassian.net/browse/MW-64 and https://wikiteq.atlassian.net/browse/MW-81 -COPY _sources/patches/skin-refreshed.patch /tmp/skin-refreshed.patch -RUN set -x; \ - cd $MW_HOME/skins/Refreshed \ - && patch -u -b includes/RefreshedTemplate.php -i /tmp/skin-refreshed.patch - # Allow to modify headelement in the Vector skin, see https://wikiteq.atlassian.net/browse/FAM-7 COPY _sources/patches/skin-vector-addVectorGeneratedSkinDataHook.patch /tmp/skin-vector-addVectorGeneratedSkinDataHook.patch RUN set -x; \ diff --git a/_sources/patches/skin-refreshed.patch b/_sources/patches/skin-refreshed.patch deleted file mode 100644 index 6cc131c7..00000000 --- a/_sources/patches/skin-refreshed.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- includes/RefreshedTemplate.20210207.php 2020-12-23 04:43:50.000000000 -0700 -+++ includes/RefreshedTemplate.php 2021-02-07 15:13:47.046242557 -0700 -@@ -384,7 +384,7 @@ - $html = $doc->loadHTML( $text, LIBXML_HTML_NOIMPLIED | LIBXML_HTML_NODEFDTD ); - if ( $html === false ) { - foreach ( libxml_get_errors() as $error ) { -- echo "\n", $error->message; -+ echo "'; - } - return false; - } From 0b3586081323e694b0b3cb97e7ef4f1e7e87f3e8 Mon Sep 17 00:00:00 2001 From: Vedmaka Date: Fri, 9 Dec 2022 22:31:55 +0400 Subject: [PATCH 18/67] Upgrades GitHub action to comply with new changes for save-state (#179) * Upgrades `actions/checkout@v2` -> `actions/checkout@v3` * Upgrades `docker/setup-buildx-action@v1` -> `docker/setup-buildx-action@v2` * Upgrades `actions/cache@v2` -> `actions/cache@v3` * Upgrades `docker/login-action@v1` -> `docker/login-action@v2` * Upgrades `docker/build-push-action@v2` -> `docker/build-push-action@v3` * Adds `install` flag to `docker/setup-buildx-action` to make use of buildx cache * Replaces `::set-output` with an environment file --- .github/workflows/docker-image.yml | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/.github/workflows/docker-image.yml b/.github/workflows/docker-image.yml index ab671781..85d35ce0 100644 --- a/.github/workflows/docker-image.yml +++ b/.github/workflows/docker-image.yml @@ -25,7 +25,7 @@ jobs: runs-on: ubuntu-latest if: github.event_name == 'push' || github.event_name == 'pull_request' steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - name: Run linter (hadolint) uses: vedmaka/hadolint-action@master @@ -45,7 +45,7 @@ jobs: if: github.event_name == 'push' || github.event_name == 'pull_request' steps: - name: Checkout - uses: actions/checkout@v2 + uses: actions/checkout@v3 - name: Generate tags id: generate @@ -96,16 +96,18 @@ jobs: echo "Final image tag to be pushed:" echo $REGISTRY_TAGS - echo "::set-output name=REGISTRY_TAGS::$REGISTRY_TAGS" + echo "REGISTRY_TAGS=$REGISTRY_TAGS" >> $GITHUB_OUTPUT - name: Set up QEMU uses: docker/setup-qemu-action@v1 - name: Set up Docker Buildx - uses: docker/setup-buildx-action@v1 + uses: docker/setup-buildx-action@v2 + with: + install: true - name: Cache Docker layers - uses: actions/cache@v2 + uses: actions/cache@v3 with: path: /tmp/.buildx-cache key: ${{ runner.os }}-buildx-${{ github.sha }} @@ -113,7 +115,7 @@ jobs: ${{ runner.os }}-buildx- - name: Login to GitHub Container Registry - uses: docker/login-action@v1 + uses: docker/login-action@v2 with: registry: ghcr.io username: ${{ github.actor }} @@ -121,7 +123,7 @@ jobs: - name: Build and push id: docker_build - uses: docker/build-push-action@v2 + uses: docker/build-push-action@v3 with: context: . platforms: linux/amd64, linux/arm64 From 4fafb972890cd7e4c5e87dd93d98a19b3b8d9d03 Mon Sep 17 00:00:00 2001 From: Vedmaka Date: Sat, 10 Dec 2022 14:28:47 +0400 Subject: [PATCH 19/67] Improves PR message --- .github/workflows/docker-image.yml | 21 +++++++++++++++------ 1 file changed, 15 insertions(+), 6 deletions(-) diff --git a/.github/workflows/docker-image.yml b/.github/workflows/docker-image.yml index 85d35ce0..c1d6cfe2 100644 --- a/.github/workflows/docker-image.yml +++ b/.github/workflows/docker-image.yml @@ -52,7 +52,7 @@ jobs: run: | # Image ID - IMAGE_ID=ghcr.io/canastawiki/canasta + IMAGE_ID=ghcr.io/canastawiki/$IMAGE_NAME # Date BDATE=$(date +%Y%m%d) @@ -73,6 +73,7 @@ jobs: # For pull requests just extract the PR number [ "${{ github.event_name }}" == "pull_request" ] && VERSION=$(echo "${{ github.ref }}" | sed -e 's,.*/\(.*\)/merge,\1,') + [ "${{ github.event_name }}" == "pull_request" ] && PR_NUMBER=$VERSION # Append version [ "${{ github.event_name }}" == "pull_request" ] && VERSION=$MEDIAWIKI_VERSION-$BDATE-$VERSION @@ -97,6 +98,10 @@ jobs: echo "Final image tag to be pushed:" echo $REGISTRY_TAGS echo "REGISTRY_TAGS=$REGISTRY_TAGS" >> $GITHUB_OUTPUT + echo "REGISTRY_TAGS_VERSION=$VERSION" >> $GITHUB_OUTPUT + [ "${{ github.event_name }}" == "pull_request" ] && SHA_SHORT=$(echo ${{ github.event.pull_request.head.sha }} | cut -c1-8) + [ "${{ github.event_name }}" == "pull_request" ] && echo "REGISTRY_TAGS_PR_NUMBER=$PR_NUMBER" >> $GITHUB_OUTPUT + [ "${{ github.event_name }}" == "pull_request" ] && echo "SHA_SHORT=$SHA_SHORT" >> $GITHUB_OUTPUT - name: Set up QEMU uses: docker/setup-qemu-action@v1 @@ -146,10 +151,14 @@ jobs: run: echo ${{ steps.generate.outputs.REGISTRY_TAGS }} - - name: Comment on PR + name: Notify about image tag if: ${{ steps.docker_build.outputs.digest }} && ${{ github.event_name == 'pull_request' }} - uses: mshick/add-pr-comment@v1 - id: comment + uses: hasura/comment-progress@v2.2.0 with: - message: "Image is built and pushed to the repository as `${{ steps.generate.outputs.REGISTRY_TAGS }}`" - repo-token: ${{ secrets.GITHUB_TOKEN }} + github-token: ${{ secrets.GITHUB_TOKEN }} + repository: ${{ github.repository }} + number: ${{ github.event.number }} + id: comment + message: ":whale: The image based on [${{ steps.generate.outputs.SHA_SHORT }}](https://github.com/WikiTeq/docker-wikiteq-canasta/pull/${{ steps.generate.outputs.REGISTRY_TAGS_PR_NUMBER }}/commits/${{ github.event.pull_request.head.sha }}) commit has been built with `${{ steps.generate.outputs.REGISTRY_TAGS_VERSION }}` tag as [${{ steps.generate.outputs.REGISTRY_TAGS }}](https://github.com/${{ github.repository }}/pkgs/container/${{ env.IMAGE_NAME }}/${{ steps.docker_build.outputs.imageid }}?tag=${{ steps.generate.outputs.REGISTRY_TAGS_VERSION }})" + recreate: true + fail: false From 530d6d3e158944660995007e109b208f943b9c0b Mon Sep 17 00:00:00 2001 From: Vedmaka Date: Sat, 10 Dec 2022 18:40:02 +0400 Subject: [PATCH 20/67] Fixes output order --- .github/workflows/docker-image.yml | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/.github/workflows/docker-image.yml b/.github/workflows/docker-image.yml index c1d6cfe2..6d0201b7 100644 --- a/.github/workflows/docker-image.yml +++ b/.github/workflows/docker-image.yml @@ -72,6 +72,7 @@ jobs: CANASTA_VERSION=$(cat VERSION) # For pull requests just extract the PR number + PR_NUMBER="" [ "${{ github.event_name }}" == "pull_request" ] && VERSION=$(echo "${{ github.ref }}" | sed -e 's,.*/\(.*\)/merge,\1,') [ "${{ github.event_name }}" == "pull_request" ] && PR_NUMBER=$VERSION @@ -94,14 +95,16 @@ jobs: echo VERSION=$VERSION echo REGISTRY_TAGS=$REGISTRY_TAGS echo headref=${{ github.head_ref }} - + + SHA_SHORT=${{ github.sha }} + [ "${{ github.event_name }}" == "pull_request" ] && SHA_SHORT=$(echo ${{ github.event.pull_request.head.sha }} | cut -c1-8) + echo "Final image tag to be pushed:" echo $REGISTRY_TAGS echo "REGISTRY_TAGS=$REGISTRY_TAGS" >> $GITHUB_OUTPUT echo "REGISTRY_TAGS_VERSION=$VERSION" >> $GITHUB_OUTPUT - [ "${{ github.event_name }}" == "pull_request" ] && SHA_SHORT=$(echo ${{ github.event.pull_request.head.sha }} | cut -c1-8) - [ "${{ github.event_name }}" == "pull_request" ] && echo "REGISTRY_TAGS_PR_NUMBER=$PR_NUMBER" >> $GITHUB_OUTPUT - [ "${{ github.event_name }}" == "pull_request" ] && echo "SHA_SHORT=$SHA_SHORT" >> $GITHUB_OUTPUT + echo "REGISTRY_TAGS_PR_NUMBER=$PR_NUMBER" >> $GITHUB_OUTPUT + echo "SHA_SHORT=$SHA_SHORT" >> $GITHUB_OUTPUT - name: Set up QEMU uses: docker/setup-qemu-action@v1 From ad610faefe2a9814db51bbd8fad1d56e3ed1ce04 Mon Sep 17 00:00:00 2001 From: Vedmaka Date: Sat, 10 Dec 2022 20:36:51 +0400 Subject: [PATCH 21/67] Fixes if statement for message step --- .github/workflows/docker-image.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/docker-image.yml b/.github/workflows/docker-image.yml index 6d0201b7..2873ad9f 100644 --- a/.github/workflows/docker-image.yml +++ b/.github/workflows/docker-image.yml @@ -155,7 +155,7 @@ jobs: - name: Notify about image tag - if: ${{ steps.docker_build.outputs.digest }} && ${{ github.event_name == 'pull_request' }} + if: github.event_name == 'pull_request' && steps.docker_build.outputs.digest != '' uses: hasura/comment-progress@v2.2.0 with: github-token: ${{ secrets.GITHUB_TOKEN }} From 29ae8f50738eb9e3b904534be0151614a2eedc6b Mon Sep 17 00:00:00 2001 From: Yaron Koren Date: Mon, 12 Dec 2022 15:32:30 -0500 Subject: [PATCH 22/67] Remove DiscussionTools extension (#171) Doesn't actually work yet, even with MW 1.39. Fixes #137. --- Dockerfile | 4 ---- 1 file changed, 4 deletions(-) diff --git a/Dockerfile b/Dockerfile index 64732900..b8db7c31 100644 --- a/Dockerfile +++ b/Dockerfile @@ -221,10 +221,6 @@ RUN set -x; \ && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Disambiguator $MW_HOME/extensions/Disambiguator \ && cd $MW_HOME/extensions/Disambiguator \ && git checkout -q b7e7fad5f9f3dccfb902a3cbfd3bf2b16df91871 \ - # DiscussionTools - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/DiscussionTools $MW_HOME/extensions/DiscussionTools \ - && cd $MW_HOME/extensions/DiscussionTools \ - && git checkout -q c6a73491a63e82e463b8e7e92f661cff83284b9a \ # DismissableSiteNotice && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/DismissableSiteNotice $MW_HOME/extensions/DismissableSiteNotice \ && cd $MW_HOME/extensions/DismissableSiteNotice \ From 8f37e5ead84b2fff0d46638b016b52b5ebc18ae4 Mon Sep 17 00:00:00 2001 From: Yaron Koren Date: Mon, 12 Dec 2022 21:44:26 -0500 Subject: [PATCH 23/67] Create RELEASE_NOTES.md (#183) --- RELEASE_NOTES.md | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 RELEASE_NOTES.md diff --git a/RELEASE_NOTES.md b/RELEASE_NOTES.md new file mode 100644 index 00000000..c9ba8952 --- /dev/null +++ b/RELEASE_NOTES.md @@ -0,0 +1,9 @@ +Canasta version history: + +- 1.0.0 - April 14, 2022 - initial version +- 1.0.1 - April 14, 2022 - update MediaWiki version to 1.35.6 +- 1.1.0 - April 29, 2022 - rename /user-extensions and /user-skins directories to /extensions and /skins +- 1.1.1 - June 16, 2022 - Disable sitemap generator by default; update CommentStreams extension; remove Favorites and MobileDetect extensions; add iputils-ping package +- 1.1.2 - July 12, 2022 - update MediaWiki version to 1.35.7; add default setting of $wgServer; add CookieWarning extension; update CommentStreams, Echo and EmbedVideo extensions; remove HeadScript extension; add poppler-utils package for PDF rendering +- 1.2.0 - October 2, 2022 - update MediaWiki version to 1.35.8; remove cfLoadExtension() and cfLoadSkin() functionality in favor of symlink-based approach; add displayWikiInfo.php script; make use of gateway.docker.internal to detect host address +- 1.2.1 - November 25, 2022 - add AArch64 support; update SimpleBatchUpload extension From a0cac6069e5a31fc77d791b92371d597d34c7e26 Mon Sep 17 00:00:00 2001 From: Yaron Koren Date: Mon, 12 Dec 2022 22:19:15 -0500 Subject: [PATCH 24/67] Remove "VectorGeneratedSkinData" hook patch (#184) * Remove "VectorGeneratedSkinData" hook patch * Delete skin-vector-addVectorGeneratedSkinDataHook.patch --- Dockerfile | 7 ------- ...skin-vector-addVectorGeneratedSkinDataHook.patch | 13 ------------- 2 files changed, 20 deletions(-) delete mode 100644 _sources/patches/skin-vector-addVectorGeneratedSkinDataHook.patch diff --git a/Dockerfile b/Dockerfile index b8db7c31..7dc736a1 100644 --- a/Dockerfile +++ b/Dockerfile @@ -548,13 +548,6 @@ RUN set -x; \ # cd $MW_HOME/skins/Refreshed \ # && patch -u -b includes/RefreshedTemplate.php -i /tmp/skin-refreshed.patch -# Allow to modify headelement in the Vector skin, see https://wikiteq.atlassian.net/browse/FAM-7 -#COPY _sources/patches/skin-vector-addVectorGeneratedSkinDataHook.patch /tmp/skin-vector-addVectorGeneratedSkinDataHook.patch -#RUN set -x; \ -# cd $MW_HOME/skins/Vector \ -# && git apply /tmp/skin-vector-addVectorGeneratedSkinDataHook.patch - - # WikiTeq's patch allowing to manage fields visibility site-wide #COPY _sources/patches/SocialProfile-disable-fields.patch /tmp/SocialProfile-disable-fields.patch #RUN set -x; \ diff --git a/_sources/patches/skin-vector-addVectorGeneratedSkinDataHook.patch b/_sources/patches/skin-vector-addVectorGeneratedSkinDataHook.patch deleted file mode 100644 index 82c492cc..00000000 --- a/_sources/patches/skin-vector-addVectorGeneratedSkinDataHook.patch +++ /dev/null @@ -1,13 +0,0 @@ -diff --git a/includes/VectorTemplate.php b/includes/VectorTemplate.php -index aff7a36..813f726 100644 ---- a/includes/VectorTemplate.php -+++ b/includes/VectorTemplate.php -@@ -183,6 +183,8 @@ class VectorTemplate extends BaseTemplate { - ]; - } - -+ Hooks::run( 'VectorGeneratedSkinData', [ $skin, &$commonSkinData ] ); -+ - return $commonSkinData; - } - From ac8d79b5bfd32166664740665e06be001d7d4e2a Mon Sep 17 00:00:00 2001 From: Yaron Koren Date: Tue, 13 Dec 2022 10:09:45 -0500 Subject: [PATCH 25/67] Add UserPageViewTracker extension (#182) Fixes #172. --- Dockerfile | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Dockerfile b/Dockerfile index 7dc736a1..063ae467 100644 --- a/Dockerfile +++ b/Dockerfile @@ -485,6 +485,10 @@ RUN set -x; \ && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/UserMerge $MW_HOME/extensions/UserMerge \ && cd $MW_HOME/extensions/UserMerge \ && git checkout -q 183bb7a8f78cbe365bec0fbd4b3ecdd4fae1a359 \ + # UserPageViewTracker (v. 0.7) + && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/UserPageViewTracker $MW_HOME/extensions/UserPageViewTracker \ + && cd $MW_HOME/extensions/UserPageViewTracker \ + && git checkout -q f4b7c20c372165541164d449c12df1e74e98ed0b \ # Variables && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Variables $MW_HOME/extensions/Variables \ && cd $MW_HOME/extensions/Variables \ From 0b7db63d1b8d263b61041b02165698a807cfb755 Mon Sep 17 00:00:00 2001 From: Yaron Koren Date: Tue, 13 Dec 2022 12:03:32 -0500 Subject: [PATCH 26/67] Add patch for LocalSettingsGenerator.php (#174) * Add patch for LocalSettingsGenerator.php * Add core-local-settings-generator.patch Fixes #148. * Fix tabs in patch * Another tab fix * Semicolon fix * Spaces fix --- Dockerfile | 5 +++++ .../core-local-settings-generator.patch | 18 ++++++++++++++++++ 2 files changed, 23 insertions(+) create mode 100644 _sources/patches/core-local-settings-generator.patch diff --git a/Dockerfile b/Dockerfile index 063ae467..01224eee 100644 --- a/Dockerfile +++ b/Dockerfile @@ -545,6 +545,11 @@ RUN set -x; \ # Patches +# Add Bootstrap to LocalSettings.php if the web installer added the Chameleon skin +COPY _sources/patches/core-local-settings-generator.patch /tmp/core-local-settings-generator.patch +RUN set -x; \ + cd $MW_HOME \ + && git apply /tmp/core-local-settings-generator.patch # TODO send to upstream, see https://wikiteq.atlassian.net/browse/MW-64 and https://wikiteq.atlassian.net/browse/MW-81 #COPY _sources/patches/skin-refreshed.patch /tmp/skin-refreshed.patch diff --git a/_sources/patches/core-local-settings-generator.patch b/_sources/patches/core-local-settings-generator.patch new file mode 100644 index 00000000..27b5c10e --- /dev/null +++ b/_sources/patches/core-local-settings-generator.patch @@ -0,0 +1,18 @@ +--- a/includes/installer/LocalSettingsGenerator.php ++++ b/includes/installer/LocalSettingsGenerator.php +@@ -48,6 +48,15 @@ class LocalSettingsGenerator { + $this->skins = $installer->getVar( '_Skins' ); + $this->IP = $installer->getVar( 'IP' ); + ++ // Patch for Canasta - if the user is enabling the Chameleon ++ // skin (likely, since all skins are selected by default), make ++ // sure the Bootstrap skin is enabled as well, to avoid a ++ // MediaWiki error. ++ if ( in_array( 'chameleon', $this->skins ) && ++ !in_array( 'Bootstrap', $this->extensions ) ) { ++ $this->extensions[] = 'Bootstrap'; ++ } ++ + $db = $installer->getDBInstaller( $installer->getVar( 'wgDBtype' ) ); + + $confItems = array_merge( From aa7422a4688c3a4b57a31ded987c04b68e6c2a2a Mon Sep 17 00:00:00 2001 From: Yaron Koren Date: Tue, 13 Dec 2022 14:49:28 -0500 Subject: [PATCH 27/67] Add TemplateWizard extension Fixes #152. --- Dockerfile | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Dockerfile b/Dockerfile index 01224eee..b71cce26 100644 --- a/Dockerfile +++ b/Dockerfile @@ -453,6 +453,10 @@ RUN set -x; \ && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/TemplateStyles $MW_HOME/extensions/TemplateStyles \ && cd $MW_HOME/extensions/TemplateStyles \ && git checkout -q 2a93b56e370ab8b8e020ed29c507104b56f1d11a \ + # TemplateWizard + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/TemplateWizard $MW_HOME/extensions/TemplateWizard \ + && cd $MW_HOME/extensions/TemplateWizard \ + && git checkout -q d486e3475f84118fd9b5c77d60254daa2f56f654 \ # Thanks && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Thanks $MW_HOME/extensions/Thanks \ && cd $MW_HOME/extensions/Thanks \ From 954cccfe83e927998706e859535bbf11b17b23eb Mon Sep 17 00:00:00 2001 From: Jeffrey Wang Date: Thu, 22 Dec 2022 10:33:04 -0800 Subject: [PATCH 28/67] Canasta 1.2.2 (#193) * Enable pushing for 1.2.x branch as well * Fix prepare_extensions_skins_symlinks() in run-apache.sh We should prepate the symlinks at the firts step (at least before we call get_mediawiki_variable() function, in other case get_mediawiki_variable does not work (throws errors) because extensions and skinks don't exist (the symlynks were not created) P.S. I don't like this idea with symlynks very much. * Version 1.2.1 * Add patch for LocalSettingsGenerator.php (1.35) (#185) * Add patch for LocalSettingsGenerator.php (1.35) * Update Dockerfile * Fully install EmailAuthorization extension (#161) * Fix prepare_extensions_skins_symlinks() in run-apache.sh We should prepate the symlinks at the firts step (at least before we call get_mediawiki_variable() function, in other case get_mediawiki_variable does not work (throws errors) because extensions and skinks don't exist (the symlynks were not created) P.S. I don't like this idea with symlynks very much. * Version 1.2.1 * Fully install EmailAuthorization extension Fixes #155 . * Fix slash * Improve comments and tabbing * Move Git submodule stuff to *after* extension retrieval * Remove stray "&&" Co-authored-by: Pavel Astakhov Co-authored-by: Jeffrey Wang * Remove now-unnecessary "path patches" (#164) * Fix prepare_extensions_skins_symlinks() in run-apache.sh We should prepate the symlinks at the firts step (at least before we call get_mediawiki_variable() function, in other case get_mediawiki_variable does not work (throws errors) because extensions and skinks don't exist (the symlynks were not created) P.S. I don't like this idea with symlynks very much. * Version 1.2.1 * Remove now-unnecessary "path patches" I would think that, with the removal of the whole cfLoad...() system, these changes to the default handling are now unnecessary. * Delete bootstrap-path.patch * Delete chameleon-path.patch Co-authored-by: Pavel Astakhov Co-authored-by: Jeffrey Wang * Version 1.2.2 * Add /update-docker-gateway.sh script (#157) * Add /update-docker-gateway.sh script Actually it adds MW_MAP_DOMAIN_TO_DOCKER_GATEWAY environment variable (disabled by default) and this allows to keep /etc/hosts intact. This change can break Visual Editor on some wiki where firewall does not allow to connect from the server itself, because it was enabled by default in Canasta to modify /etc/hosts, but it should be enabled when it is really needed only * Set MW_MAP_DOMAIN_TO_DOCKER_GATEWAY=true by default * Update RELEASE_NOTES.md for version 1.2.2 Co-authored-by: Pavel Astakhov Co-authored-by: Yaron Koren --- .github/workflows/docker-image.yml | 1 + Dockerfile | 33 ++++++------ RELEASE_NOTES.md | 1 + VERSION | 2 +- _sources/patches/bootstrap-path.patch | 16 ------ _sources/patches/chameleon-path.patch | 16 ------ .../core-local-settings-generator.patch | 18 +++++++ _sources/scripts/run-apache.sh | 24 +-------- _sources/scripts/update-docker-gateway.sh | 52 +++++++++++++++++++ 9 files changed, 92 insertions(+), 71 deletions(-) delete mode 100644 _sources/patches/bootstrap-path.patch delete mode 100644 _sources/patches/chameleon-path.patch create mode 100644 _sources/patches/core-local-settings-generator.patch create mode 100644 _sources/scripts/update-docker-gateway.sh diff --git a/.github/workflows/docker-image.yml b/.github/workflows/docker-image.yml index 2873ad9f..70d3af63 100644 --- a/.github/workflows/docker-image.yml +++ b/.github/workflows/docker-image.yml @@ -9,6 +9,7 @@ on: # Only activate for `master` branch branches: - master + - 1.2.x # Plus for all tags tags: - '*' diff --git a/Dockerfile b/Dockerfile index aa6bea4a..1e0a8c99 100644 --- a/Dockerfile +++ b/Dockerfile @@ -82,14 +82,11 @@ RUN set -x; \ FROM base as source -# MediaWiki Core +# MediaWiki core RUN set -x; \ git clone --depth 1 -b $MW_CORE_VERSION https://gerrit.wikimedia.org/r/mediawiki/core.git $MW_HOME \ && cd $MW_HOME \ - && git submodule update --init --recursive \ - # VisualEditor - && cd extensions/VisualEditor \ - && git submodule update --init + && git submodule update --init --recursive # Skins # The MonoBook, Timeless and Vector skins are bundled into MediaWiki and do not need to be separately installed. @@ -527,6 +524,15 @@ RUN set -x; \ && cd $MW_HOME/extensions/WSOAuth \ && git checkout -q 4a08a825b0a667f0a6834f58844af5fd250ceae8 +# Get all Git submodules +RUN set -x; \ + # VisualEditor + cd $MW_HOME/extensions/VisualEditor \ + && git submodule update --init \ + # EmailAuthorization + && cd $MW_HOME/extensions/EmailAuthorization \ + && git submodule update --init + # ReplaceText (switch to more recent commit due to bug on submodule HEAD) RUN set -x; \ cd $MW_HOME/extensions/ReplaceText \ @@ -563,6 +569,12 @@ RUN set -x; \ # Patches +# Add Bootstrap to LocalSettings.php if the web installer added the Chameleon skin +COPY _sources/patches/core-local-settings-generator.patch /tmp/core-local-settings-generator.patch +RUN set -x; \ + cd $MW_HOME \ + && git apply /tmp/core-local-settings-generator.patch + # SemanticResultFormats, see https://github.com/WikiTeq/SemanticResultFormats/compare/master...WikiTeq:fix1_35 COPY _sources/patches/semantic-result-formats.patch /tmp/semantic-result-formats.patch RUN set -x; \ @@ -593,16 +605,6 @@ RUN set -x; \ cd $MW_HOME/extensions/SocialProfile \ && git apply /tmp/SocialProfile-disable-fields.patch -COPY _sources/patches/bootstrap-path.patch /tmp/bootstrap-path.patch -RUN set -x; \ - cd $MW_HOME/extensions/Bootstrap \ - && patch -p1 < /tmp/bootstrap-path.patch - -COPY _sources/patches/chameleon-path.patch /tmp/chameleon-path.patch -RUN set -x; \ - cd $MW_HOME/skins/chameleon \ - && git apply /tmp/chameleon-path.patch - COPY _sources/patches/CommentStreams.REL1_35.core.hook.37a9e60.diff /tmp/CommentStreams.REL1_35.core.hook.37a9e60.diff # TODO: the Hooks is added in REL1_38, remove the patch once the core is updated to 1.38 RUN set -x; \ @@ -657,6 +659,7 @@ ENV MW_ENABLE_JOB_RUNNER=true \ MW_JOB_RUNNER_PAUSE=2 \ MW_ENABLE_TRANSCODER=true \ MW_JOB_TRANSCODER_PAUSE=60 \ + MW_MAP_DOMAIN_TO_DOCKER_GATEWAY=true \ MW_ENABLE_SITEMAP_GENERATOR=false \ MW_SITEMAP_PAUSE_DAYS=1 \ MW_SITEMAP_SUBDIR="" \ diff --git a/RELEASE_NOTES.md b/RELEASE_NOTES.md index c9ba8952..403aad52 100644 --- a/RELEASE_NOTES.md +++ b/RELEASE_NOTES.md @@ -7,3 +7,4 @@ Canasta version history: - 1.1.2 - July 12, 2022 - update MediaWiki version to 1.35.7; add default setting of $wgServer; add CookieWarning extension; update CommentStreams, Echo and EmbedVideo extensions; remove HeadScript extension; add poppler-utils package for PDF rendering - 1.2.0 - October 2, 2022 - update MediaWiki version to 1.35.8; remove cfLoadExtension() and cfLoadSkin() functionality in favor of symlink-based approach; add displayWikiInfo.php script; make use of gateway.docker.internal to detect host address - 1.2.1 - November 25, 2022 - add AArch64 support; update SimpleBatchUpload extension +- 1.2.2 - December 22, 2022 - Fix installation of EmailAuthorization extension; fix web installer to also install Boostrap extension if Chameleon skin gets installed; add MW_MAP_DOMAIN_TO_DOCKER_GATEWAY as an environment variable (set to true by default); remove patches made unnecessary by cfLoad... removal \ No newline at end of file diff --git a/VERSION b/VERSION index 6085e946..d2d61a7e 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -1.2.1 +1.2.2 \ No newline at end of file diff --git a/_sources/patches/bootstrap-path.patch b/_sources/patches/bootstrap-path.patch deleted file mode 100644 index 94b4fbf2..00000000 --- a/_sources/patches/bootstrap-path.patch +++ /dev/null @@ -1,16 +0,0 @@ -diff --git a/src/Bootstrap.php b/src/Bootstrap.php -index 235a717..0cfc92f 100644 ---- a/src/Bootstrap.php -+++ b/src/Bootstrap.php -@@ -54,9 +54,9 @@ class Bootstrap { - $configuration = []; - $configuration[ 'IP' ] = $GLOBALS[ 'IP' ]; - $configuration[ 'remoteBasePath' ] = -- $GLOBALS[ 'wgExtensionAssetsPath' ] . '/Bootstrap/resources/bootstrap'; -+ $GLOBALS[ 'wgScriptPath' ] . '/canasta-extensions/Bootstrap/resources/bootstrap'; - $configuration[ 'localBasePath' ] = -- $GLOBALS[ 'wgExtensionDirectory' ] . '/Bootstrap/resources/bootstrap'; -+ $GLOBALS[ 'IP' ] . '/canasta-extensions/Bootstrap/resources/bootstrap'; - - $setupAfterCache = new SetupAfterCache( $configuration ); - $setupAfterCache->process(); diff --git a/_sources/patches/chameleon-path.patch b/_sources/patches/chameleon-path.patch deleted file mode 100644 index 13e69eec..00000000 --- a/_sources/patches/chameleon-path.patch +++ /dev/null @@ -1,16 +0,0 @@ -diff --git a/src/Hooks/SetupAfterCache.php b/src/Hooks/SetupAfterCache.php -index 169bfa5..3d2c002 100644 ---- a/src/Hooks/SetupAfterCache.php -+++ b/src/Hooks/SetupAfterCache.php -@@ -92,9 +92,9 @@ class SetupAfterCache { - */ - protected function setInstallPaths() { - $this->configuration[ 'chameleonLocalPath' ] = -- $this->configuration['wgStyleDirectory'] . '/chameleon'; -+ $this->configuration['IP'] . '/canasta-skins/chameleon'; - $this->configuration[ 'chameleonRemotePath' ] = -- $this->configuration['wgStylePath'] . '/chameleon'; -+ $this->configuration['wgScriptPath'] . '/canasta-skins/chameleon'; - } - - protected function addLateSettings() { diff --git a/_sources/patches/core-local-settings-generator.patch b/_sources/patches/core-local-settings-generator.patch new file mode 100644 index 00000000..30fa71d3 --- /dev/null +++ b/_sources/patches/core-local-settings-generator.patch @@ -0,0 +1,18 @@ +--- a/includes/installer/LocalSettingsGenerator.php ++++ b/includes/installer/LocalSettingsGenerator.php +@@ -51,6 +51,15 @@ class LocalSettingsGenerator { + $this->skins = $installer->getVar( '_Skins' ); + $this->IP = $installer->getVar( 'IP' ); + ++ // Patch for Canasta - if the user is enabling the Chameleon ++ // skin (likely, since all skins are selected by default), make ++ // sure the Bootstrap skin is enabled as well, to avoid a ++ // MediaWiki error. ++ if ( in_array( 'chameleon', $this->skins ) && ++ !in_array( 'Bootstrap', $this->extensions ) ) { ++ $this->extensions[] = 'Bootstrap'; ++ } ++ + $db = $installer->getDBInstaller( $installer->getVar( 'wgDBtype' ) ); + + $confItems = array_merge( diff --git a/_sources/scripts/run-apache.sh b/_sources/scripts/run-apache.sh index 59288e34..9b76e352 100755 --- a/_sources/scripts/run-apache.sh +++ b/_sources/scripts/run-apache.sh @@ -7,10 +7,6 @@ get_mediawiki_variable () { php /getMediawikiSettings.php --variable="$1" --format="${2:-string}" } -get_docker_gateway () { - getent hosts "gateway.docker.internal" | awk '{ print $1 }' -} - isTrue() { case $1 in "True" | "TRUE" | "true" | 1) @@ -101,25 +97,7 @@ rsync -ah --inplace --ignore-existing --remove-source-files \ # We don't need it anymore rm -rf "$MW_ORIGIN_FILES" -# Try to fetch gateway IP from extra host -DOCKER_GATEWAY=$(get_docker_gateway) - -# Fall back to default 172.x network if unable to fetch gateway -if [ -z "$DOCKER_GATEWAY" ]; then - DOCKER_GATEWAY="172.17.0.1" -fi - -# Map host for VisualEditor -if [ -e "$MW_VOLUME/config/LocalSettings.php" ]; then - MW_SITE_SERVER=$(get_mediawiki_variable wgServer) - if [[ ! $MW_SITE_SERVER =~ ^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$ ]]; then - DOMAIN=$(echo "$MW_SITE_SERVER" | sed -e 's|^[^/]*//||' -e 's|[:/].*$||') - echo "$DOCKER_GATEWAY $DOMAIN" >> /etc/hosts - fi -fi - -# Update /etc/ssmtp/ssmtp.conf to use DOCKER_GATEWAY -sed -i "s/DOCKER_GATEWAY/$DOCKER_GATEWAY/" /etc/msmtprc +/update-docker-gateway.sh # Permissions # Note: this part if checking for root directories permissions diff --git a/_sources/scripts/update-docker-gateway.sh b/_sources/scripts/update-docker-gateway.sh new file mode 100644 index 00000000..b44d2033 --- /dev/null +++ b/_sources/scripts/update-docker-gateway.sh @@ -0,0 +1,52 @@ +#!/bin/bash + +set -x + +# read variables from LocalSettings.php +get_mediawiki_variable () { + php /getMediawikiSettings.php --variable="$1" --format="${2:-string}" +} + +get_docker_gateway () { + getent hosts "gateway.docker.internal" | awk '{ print $1 }' +} + +isTrue() { + case $1 in + "True" | "TRUE" | "true" | 1) + return 0 + ;; + *) + return 1 + ;; + esac +} + +# Try to fetch gateway IP from extra host +DOCKER_GATEWAY=$(get_docker_gateway) + +# Fall back to default 172.x network if unable to fetch gateway +if [ -z "$DOCKER_GATEWAY" ]; then + DOCKER_GATEWAY="172.17.0.1" +fi + +WG_SITE_SERVER=$(get_mediawiki_variable wgServer) + +# Map host for VisualEditor +cp /etc/hosts ~/hosts.new +sed -i '/# MW_SITE_HOST/d' ~/hosts.new +if [ -n "$WG_SITE_SERVER" ]; then + MW_SITE_HOST=$(echo "$WG_SITE_SERVER" | sed -e 's|^[^/]*//||' -e 's|[:/].*$||') + if ! isTrue "$MW_MAP_DOMAIN_TO_DOCKER_GATEWAY"; then + echo "MW_MAP_DOMAIN_TO_DOCKER_GATEWAY is not true" + elif [[ $MW_SITE_HOST =~ ^[0-9]+.[0-9]+.[0-9]+.[0-9]+$ ]]; then + echo "MW_SITE_HOST is IP address '$MW_SITE_HOST'" + else + echo "Add MW_SITE_HOST '$DOCKER_GATEWAY $MW_SITE_HOST' to /etc/hosts" + echo "$DOCKER_GATEWAY $MW_SITE_HOST # MW_SITE_HOST" >> ~/hosts.new + fi +fi +cp -f ~/hosts.new /etc/hosts + +# Update /etc/ssmtp/ssmtp.conf to use DOCKER_GATEWAY +sed -i "s/DOCKER_GATEWAY/$DOCKER_GATEWAY/" /etc/msmtprc From 8f39a12c9fe6bdb0679216f1ff44dc3015cb430a Mon Sep 17 00:00:00 2001 From: Yaron Koren Date: Wed, 28 Dec 2022 09:48:21 -0500 Subject: [PATCH 29/67] Delete backup_scripts/, backups/ and kubernetes/ directories (!) (#200) * Delete backup.db.sh * Delete backup.sh * Delete .gitignore * Delete database_backup_cron.yaml * Delete db.yaml * Delete elasticsearch.yaml * Delete web.yaml --- backup_scripts/backup.db.sh | 55 ------------------- backup_scripts/backup.sh | 15 ----- backups/.gitignore | 4 -- kubernetes/database_backup_cron.yaml | 33 ----------- kubernetes/db.yaml | 69 ----------------------- kubernetes/elasticsearch.yaml | 54 ------------------ kubernetes/web.yaml | 82 ---------------------------- 7 files changed, 312 deletions(-) delete mode 100755 backup_scripts/backup.db.sh delete mode 100755 backup_scripts/backup.sh delete mode 100644 backups/.gitignore delete mode 100644 kubernetes/database_backup_cron.yaml delete mode 100644 kubernetes/db.yaml delete mode 100644 kubernetes/elasticsearch.yaml delete mode 100644 kubernetes/web.yaml diff --git a/backup_scripts/backup.db.sh b/backup_scripts/backup.db.sh deleted file mode 100755 index 315ab8a5..00000000 --- a/backup_scripts/backup.db.sh +++ /dev/null @@ -1,55 +0,0 @@ -#!/bin/sh -# @author Greg Rundlett -# This is a quick shell script to create a sql dump of your database. -# You may need to adjust the path of mysqldump, -# or sudo apt-get install mysqldump if it doesn't exist - -# We'll make it so you can pass the database name as the first parameter -# to the script for playbook / cron / non-interactive use -# If no parameter is passed, we'll prompt you for the name -DB=$1 -if [ $# -ne 1 ]; then - echo "Here are the current databases on the server" - mysql -u root -h db -pmediawiki --batch --skip-column-names -e 'show databases;' - echo "Enter the name of the database you want to backup" - read DB -fi -# If on a Virtual Machine, use a location that is exported to the host, -# so that our backups are accessible even if the virtual machine is no longer accessible. -# backupdir="/vagrant/mediawiki/backups"; -backupdir="/backups"; - - - -if [ ! -d "$backupdir" ]; then - mkdir -p "$backupdir"; -fi - -# shell parameter expansion -# see http://www.gnu.org/software/bash/manual/html_node/Shell-Parameter-Expansion.html -# we'll start with a default backup file named '01' in the sequence -backup="${backupdir}/dump-$(date +%F).$(hostname)-${DB}.01.sql"; -# and we'll increment the counter in the filename if it already exists -i=1 -filename=$(basename "$backup") # foo.txt (basename is everything after the last slash) -extension=${filename##*.} # .txt (filename with the longest matching pattern of *. being deleted) -file=${filename%.*} # foo (filename with the shortest matching pattern of .* deleted) -file=${file%.*} # repeat the strip to get rid of the counter -# file=${filename%.{00..99}.$extension} # foo (filename with the shortest matching pattern of .[01-99].* deleted) -while [ -f $backup ]; do - backup="$backupdir/${file}.$(printf '%.2d' $(( i+1 ))).${extension}" - i=$(( i+1 )) # increments $i - # note that i is naked because $(( expression )) is arithmetic expansion in bash -done -if /usr/bin/mysqldump -u root -h db -pmediawiki --single-transaction "$DB" > "$backup"; then - echo "Backup created successfully" - echo " compressing..." - gzip $backup - ls -al "${backup}.gz"; - echo "A command such as" - echo "mysql -u root $DB <<( zcat ${backup}.gz)" - echo "will restore the database from the chosen sql dump file" -else - echo "ERROR: Something went wrong with the backup" - exit 1 -fi diff --git a/backup_scripts/backup.sh b/backup_scripts/backup.sh deleted file mode 100755 index e92fbd12..00000000 --- a/backup_scripts/backup.sh +++ /dev/null @@ -1,15 +0,0 @@ -#!/bin/sh -# @author Greg Rundlett -# This script will create backups of all the wiki databases - -wikis="de en es fr it ja ko pt ru sv zh" - -for wiki in $wikis; do - echo "working on $wiki..."; - command="/backup_scripts/backup.db.sh wiki_$wiki"; - #command="WIKI=$wiki $command"; - - echo "using $command"; - $command; - echo "done with $wiki"; -done diff --git a/backups/.gitignore b/backups/.gitignore deleted file mode 100644 index 5e7d2734..00000000 --- a/backups/.gitignore +++ /dev/null @@ -1,4 +0,0 @@ -# Ignore everything in this directory -* -# Except this file -!.gitignore diff --git a/kubernetes/database_backup_cron.yaml b/kubernetes/database_backup_cron.yaml deleted file mode 100644 index dbb1eaea..00000000 --- a/kubernetes/database_backup_cron.yaml +++ /dev/null @@ -1,33 +0,0 @@ -apiVersion: batch/v1 -kind: CronJob -metadata: - name: database-backup -spec: - schedule: "15 23 * * *" - jobTemplate: - spec: - template: - spec: - containers: - - name: database-backup - image: mysql:8.0 - imagePullPolicy: IfNotPresent - command: - - /bin/sh - args: - - /backup_scripts/backup.sh - volumeMounts: - - mountPath: /backups - name: mysql-backup-volume - - mountPath: /backup_scripts - name: mysql-backup-scripts - restartPolicy: OnFailure - volumes: - - name: mysql-backup-volume - hostPath: - path: "/opt/mediawiki/backups" - type: DirectoryOrCreate - - name: mysql-backup-scripts - hostPath: - path: "/opt/mediawiki/backup_scripts" - type: Directory diff --git a/kubernetes/db.yaml b/kubernetes/db.yaml deleted file mode 100644 index 11cf8bb1..00000000 --- a/kubernetes/db.yaml +++ /dev/null @@ -1,69 +0,0 @@ -apiVersion: v1 -kind: Service -metadata: - labels: - io.kompose.service: db - name: db -spec: - ports: - - name: "3306" - port: 3306 - targetPort: 3306 - selector: - io.kompose.service: db -status: - loadBalancer: {} ---- -apiVersion: apps/v1 -kind: Deployment -metadata: - labels: - io.kompose.service: db - name: db -spec: - replicas: 1 - selector: - matchLabels: - io.kompose.service: db - strategy: - type: Recreate - template: - metadata: - annotations: - kompose.cmd: kompose convert -f ../docker-compose.yml - kompose.version: 1.23.0 (HEAD) - creationTimestamp: null - labels: - io.kompose.service: db - spec: - containers: - - args: - - --default-authentication-plugin=mysql_native_password - - --expire_logs_days=3 - - --secure-file-priv= - env: - - name: MYSQL_DATABASE - value: mediawiki - - name: MYSQL_ROOT_HOST - value: '%' - - name: MYSQL_ROOT_PASSWORD - value: mediawiki - image: mysql:8.0 - name: db - ports: - - containerPort: 3306 - resources: {} - securityContext: - capabilities: - add: - - SYS_NICE - volumeMounts: - - mountPath: /var/lib/mysql - name: mysql-data-volume - restartPolicy: Always - volumes: - - name: mysql-data-volume - hostPath: - path: "/opt/mediawiki/mysql-data-volume" - type: DirectoryOrCreate -status: {} diff --git a/kubernetes/elasticsearch.yaml b/kubernetes/elasticsearch.yaml deleted file mode 100644 index 484c8a7f..00000000 --- a/kubernetes/elasticsearch.yaml +++ /dev/null @@ -1,54 +0,0 @@ -apiVersion: v1 -kind: Service -metadata: - labels: - io.kompose.service: elasticsearch - name: elasticsearch -spec: - ports: - - name: "9200" - port: 9200 - targetPort: 9200 - selector: - io.kompose.service: elasticsearch -status: - loadBalancer: {} ---- -apiVersion: apps/v1 -kind: Deployment -metadata: - labels: - io.kompose.service: elasticsearch - name: elasticsearch -spec: - replicas: 1 - selector: - matchLabels: - io.kompose.service: elasticsearch - strategy: - type: Recreate - template: - metadata: - labels: - io.kompose.service: elasticsearch - spec: - containers: - - env: - - name: ES_JAVA_OPTS - value: -Xms256m -Xmx512m - - name: discovery.type - value: single-node - image: docker.elastic.co/elasticsearch/elasticsearch:6.8.13 - name: elasticsearch - ports: - - containerPort: 9200 - volumeMounts: - - mountPath: /usr/share/elasticsearch/data - name: elasticsearch - restartPolicy: Always - volumes: - - name: elasticsearch - hostPath: - path: "/opt/mediawiki/elasticsearch" - type: DirectoryOrCreate -status: {} diff --git a/kubernetes/web.yaml b/kubernetes/web.yaml deleted file mode 100644 index 8cbb540d..00000000 --- a/kubernetes/web.yaml +++ /dev/null @@ -1,82 +0,0 @@ -apiVersion: v1 -kind: Service -metadata: - labels: - io.kompose.service: web - name: web -spec: - ports: - - name: "80" - port: 8081 - targetPort: 80 - selector: - io.kompose.service: web -status: - loadBalancer: { } ---- -apiVersion: apps/v1 -kind: Deployment -metadata: - labels: - io.kompose.service: web - name: web -spec: - replicas: 1 - selector: - matchLabels: - io.kompose.service: web - strategy: - type: Recreate - template: - metadata: - labels: - io.kompose.service: web - spec: - containers: - - env: - - name: MW_SITE_SERVER - value: http://localhost - - name: PHP_POST_MAX_SIZE - value: 10M - - name: PHP_UPLOAD_MAX_FILESIZE - value: 10M - image: ghcr.io/canastawiki/canasta:latest - imagePullPolicy: Always - name: web - ports: - - containerPort: 80 - resources: { } - volumeMounts: - - mountPath: "/var/www/mediawiki/w/extensions" - name: extensions - - mountPath: "/var/www/mediawiki/w/skins" - name: skins - - mountPath: "/mediawiki/config" - name: config - - mountPath: "/mediawiki/images" - name: images - - mountPath: "/mediawiki/sitemap" - name: sitemap - restartPolicy: Always - volumes: - - name: extensions - hostPath: - path: "/opt/mediawiki/extensions" - type: DirectoryOrCreate - - name: skins - hostPath: - path: "/opt/mediawiki/skins" - type: DirectoryOrCreate - - name: config - hostPath: - path: "/opt/mediawiki/config" - type: DirectoryOrCreate - - name: images - hostPath: - path: "/opt/mediawiki/images" - type: DirectoryOrCreate - - name: sitemap - hostPath: - path: "/opt/mediawiki/sitemap" - type: DirectoryOrCreate -status: { } From fb1c80bea92b57f8a2ea82057e0a0b5998057dd5 Mon Sep 17 00:00:00 2001 From: Yaron Koren Date: Thu, 5 Jan 2023 22:35:34 -0500 Subject: [PATCH 30/67] Remove SocialProfile patches (#201) * Delete SocialProfile-disable-fields.patch * Delete social-profile-REL1_35.44b4f89.diff * Update Dockerfile --- Dockerfile | 6 - .../SocialProfile-disable-fields.patch | 454 --------- .../social-profile-REL1_35.44b4f89.diff | 960 ------------------ 3 files changed, 1420 deletions(-) delete mode 100644 _sources/patches/SocialProfile-disable-fields.patch delete mode 100644 _sources/patches/social-profile-REL1_35.44b4f89.diff diff --git a/Dockerfile b/Dockerfile index b71cce26..d824ffbc 100644 --- a/Dockerfile +++ b/Dockerfile @@ -561,12 +561,6 @@ RUN set -x; \ # cd $MW_HOME/skins/Refreshed \ # && patch -u -b includes/RefreshedTemplate.php -i /tmp/skin-refreshed.patch -# WikiTeq's patch allowing to manage fields visibility site-wide -#COPY _sources/patches/SocialProfile-disable-fields.patch /tmp/SocialProfile-disable-fields.patch -#RUN set -x; \ -# cd $MW_HOME/extensions/SocialProfile \ -# && git apply /tmp/SocialProfile-disable-fields.patch - #COPY _sources/patches/bootstrap-path.patch /tmp/bootstrap-path.patch #RUN set -x; \ # cd $MW_HOME/extensions/Bootstrap \ diff --git a/_sources/patches/SocialProfile-disable-fields.patch b/_sources/patches/SocialProfile-disable-fields.patch deleted file mode 100644 index 8bbfbc24..00000000 --- a/_sources/patches/SocialProfile-disable-fields.patch +++ /dev/null @@ -1,454 +0,0 @@ -From 96d2f172b5d26da6fe6e1c6bd724026136fcc705 Mon Sep 17 00:00:00 2001 -From: Vedmaka -Date: Thu, 15 Jul 2021 15:25:51 +0300 -Subject: [PATCH] Allows managing site-wide fields visibility via - Special:ManageFields page - -- introduces new `manage-profiles-fields` right -- introduces new `Special:ManageFields` page -- adds new `user_profile_fields_disabled` table -- patches location and hometown fields display making it respect visibility settings -- makes the Special:UpdateProfile page listed ---- - SocialProfile.php | 6 ++ - SocialProfileHooks.php | 1 + - UserProfile/i18n/en.json | 14 +++ - UserProfile/i18n/qqq.json | 14 +++ - UserProfile/includes/SPUserSecurity.php | 6 ++ - UserProfile/includes/UserProfile.php | 90 ++++++++++++++++++ - UserProfile/includes/UserProfilePage.php | 20 +++- - .../includes/specials/SpecialManageFields.php | 93 +++++++++++++++++++ - .../specials/SpecialUpdateProfile.php | 2 +- - .../user_profile_fields_disabled.postgres.sql | 7 ++ - .../sql/user_profile_fields_disabled.sql | 7 ++ - 11 files changed, 257 insertions(+), 3 deletions(-) - create mode 100644 UserProfile/includes/specials/SpecialManageFields.php - create mode 100644 UserProfile/sql/user_profile_fields_disabled.postgres.sql - create mode 100644 UserProfile/sql/user_profile_fields_disabled.sql - -diff --git a/SocialProfile.php b/SocialProfile.php -index 9ff5322d..c0c7ae6b 100644 ---- a/SocialProfile.php -+++ b/SocialProfile.php -@@ -55,6 +55,7 @@ $wgAutoloadClasses['SpecialPopulateUserProfiles'] = __DIR__ . '/UserProfile/incl - $wgAutoloadClasses['SpecialToggleUserPage'] = __DIR__ . '/UserProfile/includes/specials/SpecialToggleUserPageType.php'; - $wgAutoloadClasses['SpecialUpdateProfile'] = __DIR__ . '/UserProfile/includes/specials/SpecialUpdateProfile.php'; - $wgAutoloadClasses['SpecialUploadAvatar'] = __DIR__ . '/UserProfile/includes/specials/SpecialUploadAvatar.php'; -+$wgAutoloadClasses['SpecialManageFields'] = __DIR__ . '/UserProfile/includes/specials/SpecialManageFields.php'; - $wgAutoloadClasses['UploadAvatar'] = __DIR__ . '/UserProfile/includes/avatar/UploadAvatar.php'; - $wgAutoloadClasses['RemoveAvatar'] = __DIR__ . '/UserProfile/includes/specials/SpecialRemoveAvatar.php'; - $wgAutoloadClasses['UserProfile'] = __DIR__ . '/UserProfile/includes/UserProfile.php'; -@@ -86,6 +87,11 @@ $wgSpecialPages['RemoveAvatar'] = 'RemoveAvatar'; - $wgSpecialPages['ToggleUserPage'] = 'SpecialToggleUserPage'; - $wgSpecialPages['UpdateProfile'] = 'SpecialUpdateProfile'; - $wgSpecialPages['UploadAvatar'] = 'SpecialUploadAvatar'; -+$wgSpecialPages['ManageFields'] = 'SpecialManageFields'; -+ -+// Permission to manage fields visibility site-wide -+$wgAvailableRights[] = 'manage-profiles-fields'; -+$wgGroupPermissions['sysop']['manage-profiles-fields'] = true; - - // What to display on social profile pages by default? - $wgUserProfileDisplay['board'] = true; -diff --git a/SocialProfileHooks.php b/SocialProfileHooks.php -index 2552b016..5c80aaef 100644 ---- a/SocialProfileHooks.php -+++ b/SocialProfileHooks.php -@@ -60,6 +60,7 @@ class SocialProfileHooks { - $updater->addExtensionTable( 'user_points_weekly', "$dir/UserStats/sql/user_points_weekly$dbExt.sql" ); - $updater->addExtensionTable( 'user_points_monthly', "$dir/UserStats/sql/user_points_monthly$dbExt.sql" ); - $updater->addExtensionTable( 'user_points_archive', "$dir/UserStats/sql/user_points_archive$dbExt.sql" ); -+ $updater->addExtensionTable( 'user_profile_fields_disabled', "$dir/UserProfile/sql/user_profile_fields_disabled$dbExt.sql" ); - - $updater->dropExtensionField( 'user_stats', 'stats_year_id', "$dir/UserStats/sql/patches/patch-drop-column-stats_year_id.sql" ); - $updater->dropExtensionField( 'user_profile', 'up_last_seen', "$dir/UserProfile/sql/patches/patch-drop-column-up_last_seen.sql" ); -diff --git a/UserProfile/i18n/en.json b/UserProfile/i18n/en.json -index e51ce9ab..598c3988 100644 ---- a/UserProfile/i18n/en.json -+++ b/UserProfile/i18n/en.json -@@ -8,6 +8,9 @@ - "editprofile": "Edit other users' profiles", - "populateuserprofiles": "Populate user profiles", - "populateuserprofiles-confirm": "Are you sure you want to populate existing users' profiles?", -+ "managefields": "Manage profiles fields visibility site-wide", -+ "managefields-desc": "Please select which fields will be hidden site-wide ignoring user privacy settings", -+ "managefields-saved": "Changes has been saved successfully!", - "user-time-ago": "$1 ago", - "user-awards-title": "Awards", - "user-gifts-title": "Gifts", -@@ -56,6 +59,10 @@ - "custom-info-field2": "Custom 2", - "custom-info-field3": "Custom 3", - "custom-info-field4": "Custom 4", -+ "custom-info-setting-field1": "Custom Information 1", -+ "custom-info-setting-field2": "Custom Information 2", -+ "custom-info-setting-field3": "Custom Information 3", -+ "custom-info-setting-field4": "Custom Information 4", - "custom-no-info": "No custom information", - "profile-updated-personal": "Update your profile", - "profile-not-provided": "Not provided", -@@ -66,7 +73,13 @@ - "user-no-personal-info": "No personal information", - "user-personal-info-real-name": "Real name", - "user-personal-info-location": "Location", -+ "user-personal-info-location-city": "Location (City)", -+ "user-personal-info-location-state": "Location (State)", -+ "user-personal-info-location-country": "Location (Country)", - "user-personal-info-hometown": "Hometown", -+ "user-personal-info-hometown-city": "Hometown (City)", -+ "user-personal-info-hometown-state": "Hometown (State)", -+ "user-personal-info-hometown-country": "Hometown (Country)", - "user-personal-info-birthday": "Birthday", - "user-personal-info-occupation": "Occupation", - "user-personal-info-websites": "Websites", -@@ -192,6 +205,7 @@ - "user-type-toggle-new": "Use social userpage", - "user-board-login-message": "You must be [[Special:UserLogin|logged in]] to post messages to other users", - "user-board-confirm-delete": "Are you sure you want to delete this message?", -+ "updateprofile": "Update your profile", - "removeavatar": "Remove avatar", - "removeavatar-remove-my-avatar": "Remove my avatar", - "removeavatar-remove-your-avatar": "Remove your avatar", -diff --git a/UserProfile/i18n/qqq.json b/UserProfile/i18n/qqq.json -index 40ae9778..253c605d 100644 ---- a/UserProfile/i18n/qqq.json -+++ b/UserProfile/i18n/qqq.json -@@ -16,6 +16,9 @@ - "editprofile": "Page title of Special:EditProfile, the special page which allows privileged users (usually admins, but not always) to edit other users' social profiles; generally speaking users can only edit their own social profiles, but it might be necessary for admins to be able to edit others' profiles to e.g. remove spam or personal attacks, etc.", - "populateuserprofiles": "Page title of Special:PopulateUserProfiles, the special page which privileged users (those with the populate-user-profiles user right; usually, but not necessarily always, admins) can use to populate the user_profile database table with information about existing users who already have created their own User: page. Once that process is done, users who had an existing User: page prior to SocialProfile being installed will keep their wikitext user page as the default when someone accesses their user page.", - "populateuserprofiles-confirm": "Confirmation message shown on Special:PopulateUserProfiles for privileged users ((those with the populate-user-profiles user right)", -+ "managefields": "Page title of Special:ManageFields", -+ "managefields-desc": "Intro text for the ManageFields special page", -+ "managefields-saved": "Message displayed after successful save on ManageFields page", - "user-time-ago": "Timestamp thing; $1 is an appropriate combination of {{msg-mw|userboard-time-days}} and/or {{msg-mw|userboard-time-hours}} and/or {{msg-mw|userboard-time-minutes}} and/or {{msg-mw|userboard-time-seconds}} and the actual formatted timestamp. See also {{msg-mw|userboard_posted_ago}} and [[phab:T159089]], [[phab:T69962]] & [[phab:T69964]].", - "user-awards-title": "Social profile section header; see the [[mw:File:Social user profile.png|screenshot]]. Awards a.k.a system gifts are rewards awarded to users automatically by the software once they reach certain thresholds (which site administrators or other privileged users are able to define via Special:SystemGiftManager) like having made 100 edits or gained 5 new friends, etc.", - "user-gifts-title": "Social profile section header; see the [[mw:File:Social user profile.png|screenshot]]. Gifts are little rewards that users can send to each other (as opposed to awards a.k.a system gifts, which are automatically given out once the user reaches certain thresholds). Power users (those with the giftmanager user right) can configure gifts via Special:GiftManager and regular users are also able to create and edit gifts only they can send out if the configuration variable $wgMaxCustomUserGiftCount is set to a value higher than zero in the wiki's [[mw:Manual:LocalSettings.php|LocalSettings.php]] file.", -@@ -63,6 +66,10 @@ - "custom-info-field2": "Social profile section item; see the [[mw:File:Social user profile.png|screenshot]] for details. This and the related messages ({{msg-mw|custom-info-field1}}, {{msg-mw|custom-info-field2}}, {{msg-mw|custom-info-field4}}) are meant for sites to customize as needed. For example, ArmchairGM (a sports-themed wiki; the site where the [[mw:social tools|social tools]] were originally developed) used these fields to provide the fields \"favorite sports moment\", \"least favorite sports moment\", \"favorite athlete\" and \"least favorite athlete\".", - "custom-info-field3": "Social profile section item; see the [[mw:File:Social user profile.png|screenshot]] for details. This and the related messages ({{msg-mw|custom-info-field1}}, {{msg-mw|custom-info-field2}}, {{msg-mw|custom-info-field4}}) are meant for sites to customize as needed. For example, ArmchairGM (a sports-themed wiki; the site where the [[mw:social tools|social tools]] were originally developed) used these fields to provide the fields \"favorite sports moment\", \"least favorite sports moment\", \"favorite athlete\" and \"least favorite athlete\".", - "custom-info-field4": "Social profile section item; see the [[mw:File:Social user profile.png|screenshot]] for details. This and the related messages ({{msg-mw|custom-info-field1}}, {{msg-mw|custom-info-field2}}, {{msg-mw|custom-info-field3}}) are meant for sites to customize as needed. For example, ArmchairGM (a sports-themed wiki; the site where the [[mw:social tools|social tools]] were originally developed) used these fields to provide the fields \"favorite sports moment\", \"least favorite sports moment\", \"favorite athlete\" and \"least favorite athlete\".", -+ "custom-info-setting-field1": "Social profile section item 1; for Special:ManageFields", -+ "custom-info-setting-field2": "Social profile section item 2; for Special:ManageFields", -+ "custom-info-setting-field3": "Social profile section item 3; for Special:ManageFields", -+ "custom-info-setting-field4": "Social profile section item 4; for Special:ManageFields", - "custom-no-info": "Shown on social profile pages when the \"custom information\" section is completely empty (the user hasn't filled it out yet).", - "profile-updated-personal": "Link text shown on your social profile page only to you", - "profile-not-provided": "Theoretically shown on social profile pages when certain information hasn't been provided by the user, but in reality I haven't seen this message ever in use though the PHP code certainly is using it. I need to look into this.", -@@ -73,7 +80,13 @@ - "user-no-personal-info": "Shown on social profile pages when the \"personal information\" section is completely empty (the user hasn't filled it out yet).", - "user-personal-info-real-name": "Social profile section item; see the [[mw:File:Social user profile.png|screenshot]] for details.\n{{Identical|Real name}}", - "user-personal-info-location": "Social profile section item; see the [[mw:File:Social user profile.png|screenshot]] for details.\n{{Identical|Location}}", -+ "user-personal-info-location-city": "Location (City) label displayed on Special:ManageFields", -+ "user-personal-info-location-state": "Location (State) label displayed on Special:ManageFields", -+ "user-personal-info-location-country": "Location (Country) label displayed on Special:ManageFields", - "user-personal-info-hometown": "Social profile section item; see the [[mw:File:Social user profile.png|screenshot]] for details.\n{{Identical|Hometown}}", -+ "user-personal-info-hometown-city": "Hometown (City) label displayed on Special:ManageFields", -+ "user-personal-info-hometown-state": "Hometown (State) label displayed on Special:ManageFields", -+ "user-personal-info-hometown-country": "Hometown (Country) label displayed on Special:ManageFields", - "user-personal-info-birthday": "Social profile section item; see the [[mw:File:Social user profile.png|screenshot]] for details.\n{{Identical|Birthday}}", - "user-personal-info-occupation": "Social profile section item; see the [[mw:File:Social user profile.png|screenshot]] for details.\n{{Identical|Occupation}}", - "user-personal-info-websites": "Social profile section item; see the [[mw:File:Social user profile.png|screenshot]] for details.\n{{Identical|Websites}}", -@@ -200,6 +213,7 @@ - "user-type-toggle-new": "Shown on your own social profile page; clicking on this link allows you to use the structured social profile as your primary User: page, as opposed to the regular wikitext page.", - "user-board-login-message": "Shown on the user board section of social profile pages to anonymous users informing them that they cannot post messages to the user's board.", - "user-board-confirm-delete": "Confirmation message shown via JavaScript when attempting to delete user board messages via your profile page", -+ "updateprofile": "Special:UpdateProfile page title on Special:SpecialPages list", - "removeavatar": "Page title of Special:RemoveAvatar for users who have the avatarremove user right, i.e. users who can remove others' avatars, to be displayed on Special:SpecialPages. See also {{msg-mw|avatarupload-removeavatar}}, {{msg-mw|removeavatar-remove-my-avatar}}, {{msg-mw|removeavatar-remove-my-avatar}}.", - "removeavatar-remove-my-avatar": "Page title of Special:RemoveAvatar for regular users, i.e. those who don't have the avatarremove user right, to be displayed on Special:SpecialPages. See also {{msg-mw|removeavatar}}, {{msg-mw|avatarupload-removeavatar}}, {{msg-mw|removeavatar-remove-my-avatar}}.", - "removeavatar-remove-your-avatar": "Page title of Special:RemoveAvatar for regular users, i.e. those who don't have the avatarremove user right, to be displayed on Special:RemoveAvatar. See also {{msg-mw|removeavatar}}, {{msg-mw|avatarupload-removeavatar}}, {{msg-mw|removeavatar-remove-my-avatar}}.", -diff --git a/UserProfile/includes/SPUserSecurity.php b/UserProfile/includes/SPUserSecurity.php -index 18e549f6..2a74e0fc 100644 ---- a/UserProfile/includes/SPUserSecurity.php -+++ b/UserProfile/includes/SPUserSecurity.php -@@ -149,7 +149,13 @@ class SPUserSecurity { - $profile = new UserProfile( $owner ); - $fields = $profile->profile_fields; - -+ $disabledFields = UserProfile::getDisabledFields(); -+ - foreach ( $fields as $field ) { -+ // Overrides field visibility based on UserProfile::getDisabledFields -+ if( in_array( 'up_' . $field, $disabledFields ) ) { -+ continue; -+ } - if ( self::isFieldVisible( $owner, 'up_' . $field, $viewer ) ) { - $result[] = 'up_' . $field; - } -diff --git a/UserProfile/includes/UserProfile.php b/UserProfile/includes/UserProfile.php -index 37dbd995..53b562f8 100644 ---- a/UserProfile/includes/UserProfile.php -+++ b/UserProfile/includes/UserProfile.php -@@ -273,4 +273,94 @@ class UserProfile { - - return $output; - } -+ -+ /** -+ * @return string[] -+ */ -+ public static function getDisabledFields() { -+ $dbr = wfGetDB( DB_REPLICA ); -+ return $dbr->selectFieldValues( -+ 'user_profile_fields_disabled', -+ 'up_field_name' -+ ); -+ } -+ -+ /** -+ * @param string $fieldName -+ */ -+ public static function disableField( $fieldName ) { -+ $dbw = wfGetDB( DB_MASTER ); -+ if( !$dbw->selectRow( -+ 'user_profile_fields_disabled', -+ 'up_field_name', -+ ['up_field_name' => $fieldName] -+ ) ) { -+ $dbw->insert( 'user_profile_fields_disabled', [ -+ 'up_field_name' => $fieldName -+ ] ); -+ } -+ } -+ -+ /** -+ * @param string $fieldName -+ */ -+ public static function enableField( $fieldName ) { -+ $dbw = wfGetDB( DB_MASTER ); -+ $dbw->delete( -+ 'user_profile_fields_disabled', -+ [ -+ 'up_field_name' => $fieldName -+ ] -+ ); -+ } -+ -+ public static function resetDisabledFields() { -+ $dbw = wfGetDB( DB_MASTER ); -+ $dbw->delete( -+ 'user_profile_fields_disabled', -+ [ -+ 'up_field_name IS NOT NULL' -+ ] -+ ); -+ } -+ -+ /** -+ * Returns list of all db fields being used with their i18n messages linked -+ * @return string[] -+ */ -+ public static function getFields() { -+ return [ -+ 'up_real_name' => 'user-personal-info-real-name', -+ 'up_location_city' => 'user-personal-info-location-city', -+ 'up_location_state' => 'user-personal-info-location-state', -+ 'up_location_country' => 'user-personal-info-location-country', -+ 'up_hometown_city' => 'user-personal-info-hometown-city', -+ 'up_hometown_state' => 'user-personal-info-hometown-state', -+ 'up_hometown_country' => 'user-personal-info-hometown-country', -+ 'up_birthday' => 'user-personal-info-birthday', -+ //'up_relationship' => '', -+ 'up_occupation' => 'user-personal-info-occupation', -+ //'up_companies' => '', -+ 'up_about' => 'user-personal-info-about-me', -+ 'up_places_lived' => 'user-personal-info-places-lived', -+ 'up_schools' => 'user-personal-info-schools', -+ 'up_websites' => 'user-personal-info-websites', -+ 'up_movies' => 'other-info-movies', -+ 'up_books' => 'other-info-books', -+ 'up_magazines' => 'other-info-magazines', -+ 'up_music' => 'other-info-music', -+ 'up_tv' => 'other-info-tv', -+ 'up_drinks' => 'other-info-drinks', -+ 'up_snacks' => 'other-info-snacks', -+ 'up_video_games' => 'other-info-video-games', -+ 'up_interests' => 'user-profile-section-interests', -+ //'up_quotes' => '', -+ 'up_custom_1' => 'custom-info-setting-field1', -+ 'up_custom_2' => 'custom-info-setting-field2', -+ 'up_custom_3' => 'custom-info-setting-field3', -+ 'up_custom_4' => 'custom-info-setting-field4', -+ //'up_custom_5' => 'custom-info-field5' -+ ]; -+ } -+ - } -diff --git a/UserProfile/includes/UserProfilePage.php b/UserProfile/includes/UserProfilePage.php -index 24a709a4..e193891f 100644 ---- a/UserProfile/includes/UserProfilePage.php -+++ b/UserProfile/includes/UserProfilePage.php -@@ -640,7 +640,15 @@ class UserProfilePage extends Article { - $defaultCountry = wfMessage( 'user-profile-default-country' )->inContentLanguage()->text(); - - // Current location -- $location = $profile_data['location_city'] . ', ' . $profile_data['location_state']; -+ $location = ''; -+ if ( in_array( 'up_location_city', $this->profile_visible_fields ) ) { -+ $location .= $profile_data['location_city']; -+ } -+ $location .= ', '; -+ if ( in_array( 'up_location_state', $this->profile_visible_fields ) ) { -+ $location .= $profile_data['location_state']; -+ } -+ - if ( $profile_data['location_country'] != $defaultCountry ) { - if ( $profile_data['location_city'] && $profile_data['location_state'] ) { // city AND state - $location = $profile_data['location_city'] . ', ' . -@@ -681,7 +689,15 @@ class UserProfilePage extends Article { - } - - // Hometown -- $hometown = $profile_data['hometown_city'] . ', ' . $profile_data['hometown_state']; -+ $hometown = ''; -+ if ( in_array( 'up_hometown_city', $this->profile_visible_fields ) ) { -+ $location .= $profile_data['hometown_city']; -+ } -+ $hometown .= ', '; -+ if ( in_array( 'up_hometown_state', $this->profile_visible_fields ) ) { -+ $location .= $profile_data['hometown_state']; -+ } -+ - if ( $profile_data['hometown_country'] != $defaultCountry ) { - if ( $profile_data['hometown_city'] && $profile_data['hometown_state'] ) { // city AND state - $hometown = $profile_data['hometown_city'] . ', ' . -diff --git a/UserProfile/includes/specials/SpecialManageFields.php b/UserProfile/includes/specials/SpecialManageFields.php -new file mode 100644 -index 00000000..53d24616 ---- /dev/null -+++ b/UserProfile/includes/specials/SpecialManageFields.php -@@ -0,0 +1,93 @@ -+getOutput(); -+ $request = $this->getRequest(); -+ $user = $this->getUser(); -+ -+ // Make sure user has the correct permissions -+ $this->checkPermissions(); -+ -+ // Show a message if the database is in read-only mode -+ $this->checkReadOnly(); -+ -+ // If user is blocked, they don't need to access this page -+ if ( $user->isBlocked() ) { -+ throw new UserBlockedError( $user->getBlock() ); -+ } -+ -+ // Set the page title, robot policy, etc. -+ $this->setHeaders(); -+ -+ if ( $request->wasPosted() && $user->matchEditToken( $request->getVal( 'wpEditToken' ) ) ) { -+ $fieldsToDisable = $this->getRequest()->getArray('fields', []); -+ UserProfile::resetDisabledFields(); -+ if( count( $fieldsToDisable ) ) { -+ $fieldsToDisable = array_keys( $fieldsToDisable ); -+ foreach ( $fieldsToDisable as $fieldToDisable ) { -+ UserProfile::disableField( $fieldToDisable ); -+ } -+ } -+ $this->getOutput()->addWikiMsg( 'managefields-saved' ); -+ } -+ -+ $out->addHTML( $this->displayForm() ); -+ -+ } -+ -+ /** -+ * Render the confirmation form -+ * -+ * @return string HTML -+ */ -+ private function displayForm() { -+ $form = '
'; -+ $form .= '

' . $this->msg( 'managefields-desc' )->escaped() . '

'; -+ $form .= '
'; -+ -+ $fields = UserProfile::getFields(); -+ $disabledFields = UserProfile::getDisabledFields(); -+ -+ foreach ( $fields as $field => $msg ) { -+ $form .= Html::rawElement( -+ 'div', -+ [], -+ Html::check( 'fields['.$field.']', in_array( $field, $disabledFields ), [ 'id' => $field ] ) . -+ Html::label( $this->msg( $msg ), $field ) -+ ); -+ } -+ -+ $form .= Html::hidden( 'wpEditToken', $this->getUser()->getEditToken() ); -+ // passing null as the 1st argument makes the button use the browser default text -+ // (on Firefox 72 with English localization this is "Submit Query" which is good enough, -+ // since MW core lacks a generic "submit" message and I don't feel like introducing -+ // a new i18n msg just for this button...) -+ $form .= Html::submitButton( null, [ 'name' => 'wpSubmit' ] ); -+ $form .= '
'; -+ return $form; -+ } -+} -diff --git a/UserProfile/includes/specials/SpecialUpdateProfile.php b/UserProfile/includes/specials/SpecialUpdateProfile.php -index a0187178..98430a38 100644 ---- a/UserProfile/includes/specials/SpecialUpdateProfile.php -+++ b/UserProfile/includes/specials/SpecialUpdateProfile.php -@@ -12,7 +12,7 @@ use MediaWiki\User\UserIdentity; - * @license GPL-2.0-or-later - */ - --class SpecialUpdateProfile extends UnlistedSpecialPage { -+class SpecialUpdateProfile extends SpecialPage { - - public function __construct() { - parent::__construct( 'UpdateProfile' ); -diff --git a/UserProfile/sql/user_profile_fields_disabled.postgres.sql b/UserProfile/sql/user_profile_fields_disabled.postgres.sql -new file mode 100644 -index 00000000..16487c16 ---- /dev/null -+++ b/UserProfile/sql/user_profile_fields_disabled.postgres.sql -@@ -0,0 +1,7 @@ -+-- Postgres version -+-- Table structure for table `user_profile_fields_disabled` -+-- -+ -+CREATE TABLE user_profile_fields_disabled ( -+ up_field_name TEXT NOT NULL -+); -diff --git a/UserProfile/sql/user_profile_fields_disabled.sql b/UserProfile/sql/user_profile_fields_disabled.sql -new file mode 100644 -index 00000000..9614a79a ---- /dev/null -+++ b/UserProfile/sql/user_profile_fields_disabled.sql -@@ -0,0 +1,7 @@ -+-- -+-- Table structure for table `user_profile_fields_disabled` -+-- -+ -+CREATE TABLE IF NOT EXISTS /*_*/user_profile_fields_disabled ( -+ `up_field_name` varchar(255) NOT NULL -+) /*$wgDBTableOptions*/; --- -2.30.1 (Apple Git-130) - diff --git a/_sources/patches/social-profile-REL1_35.44b4f89.diff b/_sources/patches/social-profile-REL1_35.44b4f89.diff deleted file mode 100644 index 4f35511e..00000000 --- a/_sources/patches/social-profile-REL1_35.44b4f89.diff +++ /dev/null @@ -1,960 +0,0 @@ -From 44b4f89caa781ec8cfa3a864e65062d0d5fa4ecb Mon Sep 17 00:00:00 2001 -From: Jack Phoenix -Date: Sun, 16 May 2021 10:13:15 +0300 -Subject: [PATCH] [SECURITY] Fix XSS in various SystemGifts/UserGifts-related special pages - -Also: -* Adjust escaping as appropriate -** E.g. LinkRenderer escapes the output by default so passing $this->msg( ... )->text() to it is not just safe but expected; whereas passing $this->msg( ... )->escaped() would potentially result in double escaping -** Also htmlspecialchars( $this->msg( ... )->plain() ) is ugly and overly verbose when $this->msg( ... )->escaped() literally does the same -* Pass Message objects to OutputPage#setPageTitle for readability -* Make timestamps on Special:ViewSystemGift/Special:ViewGift more human-readable (thanks legoktm!) -** Previously they were like "2020-07-18 23:25:37" but now they're like "23:25, 18 July 2020" and properly escaped on top of that - -Bug: T281043 -Change-Id: Id915eba45497a1a0dc1c4e00818a2fd4c0ce55d3 -(cherry picked from commit 58d2420c0f726cd469c638043ed66a4374b136f2) ---- - -diff --git a/SystemGifts/includes/specials/SpecialRemoveMasterSystemGift.php b/SystemGifts/includes/specials/SpecialRemoveMasterSystemGift.php -index 97cfe01..179e86e 100644 ---- a/SystemGifts/includes/specials/SpecialRemoveMasterSystemGift.php -+++ b/SystemGifts/includes/specials/SpecialRemoveMasterSystemGift.php -@@ -71,8 +71,8 @@ - $this->gift_id = $request->getInt( 'gift_id', $par ); - - if ( !$this->gift_id || !is_numeric( $this->gift_id ) ) { -- $out->setPageTitle( $this->msg( 'ga-error-title' )->plain() ); -- $out->addHTML( $this->msg( 'ga-error-message-invalid-link' )->plain() ); -+ $out->setPageTitle( $this->msg( 'ga-error-title' ) ); -+ $out->addHTML( $this->msg( 'ga-error-message-invalid-link' )->escaped() ); - return false; - } - -@@ -102,14 +102,14 @@ - $this->deleteImage( $this->gift_id, 'l' ); - $this->deleteImage( $this->gift_id, 'ml' ); - -- $out->setPageTitle( $this->msg( 'ga-remove-success-title', $gift['gift_name'] )->plain() ); -+ $out->setPageTitle( $this->msg( 'ga-remove-success-title', $gift['gift_name'] ) ); - - $output = ' -
' . -- $this->msg( 'ga-remove-success-message', $gift['gift_name'] )->plain() . -+ $this->msg( 'ga-remove-success-message', $gift['gift_name'] )->escaped() . - '
-
'; - -@@ -131,24 +131,24 @@ - $systemGiftIcon = new SystemGiftIcon( $this->gift_id, 'l' ); - $icon = $systemGiftIcon->getIconHTML(); - -- $this->getOutput()->setPageTitle( $this->msg( 'ga-remove-title', $gift['gift_name'] )->plain() ); -+ $this->getOutput()->setPageTitle( $this->msg( 'ga-remove-title', $gift['gift_name'] ) ); - - $output = ' -
-
' . -- $this->msg( 'ga-delete-message', $gift['gift_name'] ) . -+ $this->msg( 'ga-delete-message', $gift['gift_name'] )->escaped() . - '
-
' . - $icon . -- '
' . $gift['gift_name'] . '
-+ '
' . htmlspecialchars( $gift['gift_name'], ENT_QUOTES ) . '
-
-
-
-- -- -+ -+ -
- -
'; -diff --git a/SystemGifts/includes/specials/SpecialSystemGiftManager.php b/SystemGifts/includes/specials/SpecialSystemGiftManager.php -index 651f445..f2464e7 100644 ---- a/SystemGifts/includes/specials/SpecialSystemGiftManager.php -+++ b/SystemGifts/includes/specials/SpecialSystemGiftManager.php -@@ -58,7 +58,7 @@ - ); - $out->addHTML( - '' . -- $this->msg( 'ga-created' )->plain() . -+ $this->msg( 'ga-created' )->escaped() . - '

' - ); - } else { -@@ -72,7 +72,7 @@ - ); - $out->addHTML( - '' . -- $this->msg( 'ga-saved' )->plain() . -+ $this->msg( 'ga-saved' )->escaped() . - '

' - ); - } -@@ -86,7 +86,7 @@ - $out->addHTML( - '' -+ $this->msg( 'ga-addnew' )->escaped() . '' - ); - $out->addHTML( $this->displayGiftList() ); - } -@@ -114,12 +114,12 @@ - $removePage = SpecialPage::getTitleFor( 'RemoveMasterSystemGift' ); - $deleteLink = '' . $this->msg( 'delete' )->plain() . ''; -+ '">' . $this->msg( 'delete' )->escaped() . ''; - } - - $output .= '
- ' . -- $gift['gift_name'] . ' ' . -+ htmlspecialchars( $gift['gift_name'], ENT_QUOTES ) . ' ' . - $deleteLink . '
' . "\n"; - } - } -@@ -127,9 +127,9 @@ - return '
' . $output . '
'; - } - -- function displayForm( $gift_id ) { -+ function displayForm( int $gift_id ) { - $form = ''; -+ '">' . $this->msg( 'ga-viewlist' )->escaped() . ''; - - if ( $gift_id ) { - $gift = SystemGifts::getGift( $gift_id ); -@@ -138,15 +138,19 @@ - $form .= '
- - -- -- -+ -+ - - -- -- -+ -+ - - -- -+ - - - -- -+ - -+ ( isset( $gift['gift_threshold'] ) && $gift['gift_threshold'] ? (int)$gift['gift_threshold'] : '' ) . '"/> - '; - - if ( $gift_id ) { -@@ -174,27 +178,27 @@ - $icon = $systemGiftIcon->getIconHTML(); - - $form .= ' -- -+ - - '; - } - - if ( isset( $gift['gift_id'] ) ) { -- $button = $this->msg( 'edit' )->plain(); -+ $button = $this->msg( 'edit' )->escaped(); - } else { -- $button = $this->msg( 'ga-create-gift' )->plain(); -+ $button = $this->msg( 'ga-create-gift' )->escaped(); - } - - $form .= ' - - -
' . $this->msg( 'ga-giftname' )->plain() . '' . $this->msg( 'ga-giftname' )->escaped() . '
' . $this->msg( 'ga-giftdesc' )->plain() . '' . $this->msg( 'ga-giftdesc' )->escaped() . '
' . $this->msg( 'ga-gifttype' )->plain() . '' . $this->msg( 'ga-gifttype' )->escaped() . ' -
' . $this->msg( 'ga-threshold' )->plain() . '' . $this->msg( 'ga-threshold' )->escaped() . '
' . $this->msg( 'ga-giftimage' )->plain() . '' . $this->msg( 'ga-giftimage' )->escaped() . '' . - $icon . - '' . -- $this->msg( 'ga-img' )->plain() . ' -+ $this->msg( 'ga-img' )->escaped() . ' -
-- -+ - - -- -+ -
-diff --git a/SystemGifts/includes/specials/SpecialSystemGiftManagerLogo.php b/SystemGifts/includes/specials/SpecialSystemGiftManagerLogo.php -index 54baee9..a729a5c 100644 ---- a/SystemGifts/includes/specials/SpecialSystemGiftManagerLogo.php -+++ b/SystemGifts/includes/specials/SpecialSystemGiftManagerLogo.php -@@ -167,7 +167,7 @@ - * If there was no filename or a zero size given, give up quick. - */ - if ( trim( $this->mOname ) == '' || empty( $this->mUploadSize ) ) { -- return $this->mainUploadForm( '
  • ' . $this->msg( 'emptyfile' )->plain() . '
  • ' ); -+ return $this->mainUploadForm( '
  • ' . $this->msg( 'emptyfile' )->escaped() . '
  • ' ); - } - - # Chop off any directories in the given filename -@@ -236,7 +236,7 @@ - } - - if ( $this->mUploadSize == 0 ) { -- $warning .= '
  • ' . $this->msg( 'emptyfile' )->plain() . '
  • '; -+ $warning .= '
  • ' . $this->msg( 'emptyfile' )->escaped() . '
  • '; - } - - if ( $warning != '' ) { -@@ -512,8 +512,8 @@ - $ext = 'jpg'; - $ts = rand(); - -- $output = '

    ' . $this->msg( 'ga-uploadsuccess' )->plain() . '

    '; -- $output .= '
    ' . $this->msg( 'ga-imagesbelow' )->plain() . '
    '; -+ $output = '

    ' . $this->msg( 'ga-uploadsuccess' )->escaped() . '

    '; -+ $output .= '
    ' . $this->msg( 'ga-imagesbelow' )->escaped() . '
    '; - if ( $status == 1 ) { - $ext = 'gif'; - } -@@ -526,33 +526,33 @@ - - $output .= ' - -- -+ - - - -- -+ - - - -- -+ - - - -- -+ - - - - - '; - - $systemGiftManager = SpecialPage::getTitleFor( 'SystemGiftManager' ); - $output .= $this->getLanguage()->pipeList( [ - '' -+ $this->msg( 'ga-back-edit-gift' )->escaped() . '' - ] ); - $output .= '
    ' . $this->msg( 'ga-large' )->plain() . '' . $this->msg( 'ga-large' )->escaped() . '
    ' . $this->msg( 'ga-mediumlarge' )->plain() . '' . $this->msg( 'ga-mediumlarge' )->escaped() . '
    ' . $this->msg( 'ga-medium' )->plain() . '' . $this->msg( 'ga-medium' )->escaped() . '
    ' . $this->msg( 'ga-small' )->plain() . '' . $this->msg( 'ga-small' )->escaped() . '
    -- -+ -
    ' . -- $this->msg( 'ga-back-gift-list' )->plain() . ' ', -+ $this->msg( 'ga-back-gift-list' )->escaped() . ' ', - ' ' . -- $this->msg( 'ga-back-edit-gift' )->plain() . '
    '; - $this->getOutput()->addHTML( $output ); -@@ -563,10 +563,10 @@ - */ - function uploadError( $error ) { - $out = $this->getOutput(); -- $sub = $this->msg( 'uploadwarning' )->plain(); -+ $sub = $this->msg( 'uploadwarning' )->escaped(); - $out->addHTML( "

    {$sub}

    \n" ); - $out->addHTML( "

    {$error}

    \n" ); -- $out->addHTML( '
    ' ); -+ $out->addHTML( '
    ' ); - } - - /** -@@ -586,7 +586,7 @@ - } - - $out = $this->getOutput(); -- $sub = $this->msg( 'uploadwarning' )->plain(); -+ $sub = $this->msg( 'uploadwarning' )->escaped(); - $out->addHTML( "

    {$sub}

    \n" ); - $out->addHTML( "
      {$warning}

    \n" ); - -@@ -616,7 +616,7 @@ - - - -- plain() . "' /> -+ escaped() . "' /> - - - -@@ -635,22 +635,22 @@ - - $out = $this->getOutput(); - if ( $msg != '' ) { -- $sub = $this->msg( 'uploaderror' )->plain(); -+ $sub = $this->msg( 'uploaderror' )->escaped(); - $out->addHTML( "

    {$sub}

    \n" . - "

    {$msg}

    \n" ); - } - -- $ulb = $this->msg( 'uploadbtn' )->plain(); -+ $ulb = $this->msg( 'uploadbtn' )->escaped(); - - $source = null; - - if ( $wgUseCopyrightUpload ) { - $source = " -- " . $this->msg( 'filestatus' )->plain() . " -+ " . $this->msg( 'filestatus' )->escaped() . " - mUploadCopyStatus ) . "\" size='40' /> - -- " . $this->msg( 'filesource' )->plain() . " -+ " . $this->msg( 'filesource' )->escaped() . " - mUploadSource ) . "\" /> - "; -@@ -661,7 +661,7 @@ - $output = ' - - - - -@@ -680,7 +680,7 @@ -
    ' . -- $this->msg( 'ga-currentimage' )->plain() . -+ $this->msg( 'ga-currentimage' )->escaped() . - '
    - - - -diff --git a/SystemGifts/includes/specials/SpecialViewSystemGift.php b/SystemGifts/includes/specials/SpecialViewSystemGift.php -index 5297fbb..dbc599d 100644 ---- a/SystemGifts/includes/specials/SpecialViewSystemGift.php -+++ b/SystemGifts/includes/specials/SpecialViewSystemGift.php -@@ -36,8 +36,8 @@ - // numeric, display an error message - $giftId = $this->getRequest()->getInt( 'gift_id' ); - if ( !$giftId || !is_numeric( $giftId ) ) { -- $out->setPageTitle( $this->msg( 'ga-error-title' )->plain() ); -- $out->addHTML( $this->msg( 'ga-error-message-invalid-link' )->plain() ); -+ $out->setPageTitle( $this->msg( 'ga-error-title' ) ); -+ $out->addHTML( $this->msg( 'ga-error-message-invalid-link' )->escaped() ); - return; - } - -@@ -73,7 +73,7 @@ - [ 'actor' => [ 'JOIN', 'actor_id = sg_actor' ] ] - ); - -- $out->setPageTitle( $this->msg( 'ga-gift-title', $gift['user_name'], $gift['name'] )->parse() ); -+ $out->setPageTitle( $this->msg( 'ga-gift-title', $gift['user_name'], $gift['name'] ) ); - - $output .= '
    ' . -- $this->msg( 'ga-file-instructions' )->escaped() . $this->msg( 'ga-choosefile' )->plain() . '
    -+ $this->msg( 'ga-file-instructions' )->escaped() . $this->msg( 'ga-choosefile' )->escaped() . '
    - -
    '; - $form .= ' -- -+ - - - -- -+ - - '; -@@ -278,14 +278,14 @@ - $privateSelected = ' selected="selected"'; - } - $form .= ' -- -+ - -@@ -298,27 +298,27 @@ - $icon = $userGiftIcon->getIconHTML(); - - $form .= ' -- -+ - - '; - } - - if ( isset( $gift['gift_id'] ) ) { -- $button = $this->msg( 'edit' )->plain(); -+ $button = $this->msg( 'edit' )->escaped(); - } else { -- $button = $this->msg( 'g-create-gift' )->plain(); -+ $button = $this->msg( 'g-create-gift' )->escaped(); - } - - $form .= ' - - -
    ' . htmlspecialchars( $this->msg( 'g-gift-name' )->plain() ) . '' . $this->msg( 'g-gift-name' )->escaped() . '
    ' . htmlspecialchars( $this->msg( 'giftmanager-description' )->plain() ) . '' . $this->msg( 'giftmanager-description' )->escaped() . '
    ' . htmlspecialchars( $this->msg( 'giftmanager-access' )->plain() ) . '' . $this->msg( 'giftmanager-access' )->escaped() . ' - -
    ' . htmlspecialchars( $this->msg( 'giftmanager-giftimage' )->plain() ) . '' . $this->msg( 'giftmanager-giftimage' )->escaped() . '' . $icon . - '

    - ' . -- htmlspecialchars( $this->msg( 'giftmanager-image' )->plain() ) . ' -+ $this->msg( 'giftmanager-image' )->escaped() . ' -

    -- -+ - -- -- -+ -+ -
    -diff --git a/UserGifts/includes/specials/SpecialGiftManagerLogo.php b/UserGifts/includes/specials/SpecialGiftManagerLogo.php -index dafa924..4f891d1 100644 ---- a/UserGifts/includes/specials/SpecialGiftManagerLogo.php -+++ b/UserGifts/includes/specials/SpecialGiftManagerLogo.php -@@ -257,7 +257,7 @@ - } - - if ( $this->mUploadSize == 0 ) { -- $warning .= '
  • ' . htmlspecialchars( $this->msg( 'emptyfile' )->plain() ) . '
  • '; -+ $warning .= '
  • ' . $this->msg( 'emptyfile' )->escaped() . '
  • '; - } - - if ( $warning != '' ) { -@@ -537,8 +537,8 @@ - - $ext = 'jpg'; - -- $output = '

    ' . htmlspecialchars( $this->msg( 'g-uploadsuccess' )->plain() ) . '

    '; -- $output .= '
    ' . htmlspecialchars( $this->msg( 'g-imagesbelow' )->plain() ) . '
    '; -+ $output = '

    ' . $this->msg( 'g-uploadsuccess' )->escaped() . '

    '; -+ $output .= '
    ' . $this->msg( 'g-imagesbelow' )->escaped() . '
    '; - if ( $status == 1 ) { - $ext = 'gif'; - } -@@ -551,22 +551,22 @@ - $ts = rand(); - - $output .= ''; -- $output .= ' -+ $output .= ' - '; -- $output .= ' -+ $output .= ' - '; -- $output .= ' -+ $output .= ' - '; -- $output .= ' -+ $output .= ' - '; -- $output .= ''; -+ $output .= ''; - - $giftManager = SpecialPage::getTitleFor( 'GiftManager' ); - $output .= $this->getLanguage()->pipeList( [ - '' -+ '">' . $this->msg( 'g-back-edit-gift' )->escaped() . '' - ] ); - $output .= '
    ' . htmlspecialchars( $this->msg( 'g-large' )->plain() ) . '
    ' . $this->msg( 'g-large' )->escaped() . '
    ' . htmlspecialchars( $this->msg( 'g-mediumlarge' )->plain() ) . '
    ' . $this->msg( 'g-mediumlarge' )->escaped() . '
    ' . htmlspecialchars( $this->msg( 'g-medium' )->plain() ) . '
    ' . $this->msg( 'g-medium' )->escaped() . '
    ' . htmlspecialchars( $this->msg( 'g-small' )->plain() ) . '
    ' . $this->msg( 'g-small' )->escaped() . '
    ' . -- htmlspecialchars( $this->msg( 'g-back-gift-list' )->plain() ) . ' ', -+ $this->msg( 'g-back-gift-list' )->escaped() . ' ', - ' ' . htmlspecialchars( $this->msg( 'g-back-edit-gift' )->plain() ) . '
    '; - $this->getOutput()->addHTML( $output ); -@@ -577,10 +577,10 @@ - */ - function uploadError( $error ) { - $out = $this->getOutput(); -- $sub = htmlspecialchars( $this->msg( 'uploadwarning' )->plain() ); -+ $sub = $this->msg( 'uploadwarning' )->escaped(); - $out->addHTML( "

    {$sub}

    \n" ); - $out->addHTML( "

    {$error}

    \n" ); -- $out->addHTML( '
    ' ); -+ $out->addHTML( '
    ' ); - } - - /** -@@ -601,7 +601,7 @@ - return; - } - -- $sub = $this->msg( 'uploadwarning' )->plain(); -+ $sub = $this->msg( 'uploadwarning' )->escaped(); - $out->addHTML( "

    {$sub}

    \n" ); - $out->addHTML( "
      {$warning}

    \n" ); - -@@ -624,14 +624,14 @@ - mSessionKey ) . "\" /> - mUploadDescription ) . "\" /> - mDestFile ) . "\" /> -- mWatchthis ) ) . "\" /> -+ mWatchthis ) . "\" /> - {$copyright} - - - - - - - -diff --git a/UserGifts/includes/specials/SpecialGiveGift.php b/UserGifts/includes/specials/SpecialGiveGift.php -index 1b18918..8596675 100644 ---- a/UserGifts/includes/specials/SpecialGiveGift.php -+++ b/UserGifts/includes/specials/SpecialGiveGift.php -@@ -277,6 +277,10 @@ -
    -
    ' . $this->msg( 'g-add-message' )->escaped() . '
    - -+
    ' . $this->msg( -+ 'g-characters-left', -+ '255' -+ )->parse() . '
    -
    - - -@@ -407,7 +411,7 @@ - 'class' => 'g-give-checkbox', - 'id' => "nojs-gift-{$gift['id']}" - ] ); -- $output .= Html::label( $this->msg( 'g-give-this-gift' )->escaped(), "nojs-gift-{$gift['id']}" ); -+ $output .= Html::label( $this->msg( 'g-give-this-gift' )->text(), "nojs-gift-{$gift['id']}" ); - $output .= '
    -
    '; - if ( $x == count( $gifts ) || $x != 1 && $x % $per_row == 0 ) { -@@ -429,13 +433,13 @@ - if ( $page > 1 ) { - $output .= $linkRenderer->makeLink( - $giveGiftLink, -- $this->msg( 'g-previous' )->plain(), -+ $this->msg( 'g-previous' )->text(), - [], - [ - 'user' => $user_name, - 'page' => ( $page - 1 ) - ] -- ) . htmlspecialchars( $this->msg( 'word-separator' )->plain() ); -+ ) . $this->msg( 'word-separator' )->escaped(); - } - - if ( ( $total % $per_page ) != 0 ) { -@@ -456,15 +460,15 @@ - 'user' => $user_name, - 'page' => $i - ] -- ) . htmlspecialchars( $this->msg( 'word-separator' )->plain() ); -+ ) . $this->msg( 'word-separator' )->escaped(); - } - } - - if ( ( $total - ( $per_page * $page ) ) > 0 ) { -- $output .= $this->msg( 'word-separator' )->plain() . -+ $output .= $this->msg( 'word-separator' )->escaped() . - $linkRenderer->makeLink( - $giveGiftLink, -- $this->msg( 'g-next' )->plain(), -+ $this->msg( 'g-next' )->text(), - [], - [ - 'user' => $user_name, -diff --git a/UserGifts/includes/specials/SpecialViewGift.php b/UserGifts/includes/specials/SpecialViewGift.php -index 36d3e25..aa86af9 100644 ---- a/UserGifts/includes/specials/SpecialViewGift.php -+++ b/UserGifts/includes/specials/SpecialViewGift.php -@@ -36,7 +36,7 @@ - $giftId = $this->getRequest()->getInt( 'gift_id' ); - if ( !$giftId || !is_numeric( $giftId ) ) { - $out->setPageTitle( $this->msg( 'g-error-title' )->plain() ); -- $out->addHTML( htmlspecialchars( $this->msg( 'g-error-message-invalid-link' )->plain() ) ); -+ $out->addHTML( $this->msg( 'g-error-message-invalid-link' )->escaped() ); - return; - } - -@@ -87,37 +87,39 @@ - - $userGiftIcon = new UserGiftIcon( $gift['gift_id'], 'l' ); - $icon = $userGiftIcon->getIconHTML(); -- -- $message = $out->parseAsContent( trim( $gift['message'] ), false ); -+ $lang = $this->getLanguage(); -+ // because "23:25, 18 July 2020" is more readable than "2020-07-18 23:25:37" (thanks legoktm!) -+ $humanFriendlyTimestamp = $lang->userTimeAndDate( $gift['timestamp'], $user ); - - $output .= '
    '; - $output .= '
    ' . - $icon . - '
    ' . htmlspecialchars( $gift['name'] ) . '
    --
    (' . $gift['timestamp'] . ')
    -+
    (' . htmlspecialchars( $humanFriendlyTimestamp, ENT_QUOTES ) . ')
    -
    ' . $this->msg( - 'g-from', - $sender->getName() - )->parse() . '
    '; -- if ( $message ) { -+ if ( isset( $gift['message'] ) && $gift['message'] ) { -+ $message = $out->parseAsContent( trim( $gift['message'] ), false ); - $output .= '
    ' . $message . '
    '; - } - $output .= '
    -
    ' . htmlspecialchars( $gift['description'] ) . '
    -
    - ' . -- htmlspecialchars( $this->msg( 'g-to-another' )->plain() ) . ''; -+ $this->msg( 'g-to-another' )->escaped() . ''; - if ( $gift['actor_to'] == $user->getActorId() ) { - $output .= $this->msg( 'pipe-separator' )->escaped(); - $output .= '' . -- htmlspecialchars( $this->msg( 'g-remove-gift' )->plain() ) . ''; -+ $this->msg( 'g-remove-gift' )->escaped() . ''; - } - $output .= '
    -
    '; - - $output .= '
    -
    ' . -- htmlspecialchars( $this->msg( 'g-recent-recipients' )->plain() ) . -+ $this->msg( 'g-recent-recipients' )->escaped() . - '
    -
    ' . - $this->msg( 'g-given', $gift['gift_count'] )->parse() . -@@ -139,7 +141,7 @@ - $out->addHTML( $output ); - } else { - $out->setPageTitle( $this->msg( 'g-error-title' )->plain() ); -- $out->addHTML( htmlspecialchars( $this->msg( 'g-error-message-invalid-link' )->plain() ) ); -+ $out->addHTML( $this->msg( 'g-error-message-invalid-link' )->escaped() ); - } - } - } -diff --git a/UserGifts/includes/specials/SpecialViewGifts.php b/UserGifts/includes/specials/SpecialViewGifts.php -index 1b7ef03..f5972dd 100644 ---- a/UserGifts/includes/specials/SpecialViewGifts.php -+++ b/UserGifts/includes/specials/SpecialViewGifts.php -@@ -78,7 +78,7 @@ - */ - if ( $user_id == 0 ) { - $out->setPageTitle( $this->msg( 'g-error-title' )->plain() ); -- $out->addHTML( htmlspecialchars( $this->msg( 'g-error-message-no-user' )->plain() ) ); -+ $out->addHTML( $this->msg( 'g-error-message-no-user' )->escaped() ); - return; - } - -@@ -146,7 +146,7 @@ - $rel->clearUserGiftStatus( $gift['id'] ); - } - $output .= '' . -- htmlspecialchars( $this->msg( 'g-new' )->plain() ) . -+ $this->msg( 'g-new' )->escaped() . - ''; - } - $output .= '
    '; -@@ -159,14 +159,14 @@ - '
    -
    - ' . -- htmlspecialchars( $this->msg( 'g-to-another' )->plain() ) . -+ $this->msg( 'g-to-another' )->escaped() . - ''; - if ( $rel->user_name == $currentUser->getName() ) { - $output .= ' '; - $output .= $this->msg( 'pipe-separator' )->escaped(); - $output .= ' '; - $output .= '' . -- htmlspecialchars( $this->msg( 'g-remove-gift' )->plain() ) . ''; -+ $this->msg( 'g-remove-gift' )->escaped() . ''; - } - $output .= '
    -
    '; -@@ -191,13 +191,13 @@ - if ( $page > 1 ) { - $output .= $linkRenderer->makeLink( - $pageLink, -- $this->msg( 'g-previous' )->plain(), -+ $this->msg( 'g-previous' )->text(), - [], - [ - 'user' => $user_name, - 'page' => ( $page - 1 ) - ] -- ) . htmlspecialchars( $this->msg( 'word-separator' )->plain() ); -+ ) . $this->msg( 'word-separator' )->escaped(); - } - - if ( ( $total % $per_page ) != 0 ) { -@@ -222,15 +222,15 @@ - 'user' => $user_name, - 'page' => $i - ] -- ) . $this->msg( 'word-separator' )->plain(); -+ ) . $this->msg( 'word-separator' )->escaped(); - } - } - - if ( ( $total - ( $per_page * $page ) ) > 0 ) { -- $output .= htmlspecialchars( $this->msg( 'word-separator' )->plain() ) . -+ $output .= $this->msg( 'word-separator' )->escaped() . - $linkRenderer->makeLink( - $pageLink, -- $this->msg( 'g-next' )->plain(), -+ $this->msg( 'g-next' )->text(), - [], - [ - 'user' => $user_name, From b650623b91a59d5e79afea386b9ae74939ef6421 Mon Sep 17 00:00:00 2001 From: Yaron Koren Date: Tue, 17 Jan 2023 13:10:17 -0500 Subject: [PATCH 31/67] Add header warning to some special pages if $wgSMTP not set (#194) * Add showSMTPWarning() * Add handling for $wgEnableEmail and $wgEnableUserEmail * Add fixes suggested by @pastakhov * Add missing semicolon * More fixes for SMTP warning code --- _sources/canasta/CanastaUtils.php | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/_sources/canasta/CanastaUtils.php b/_sources/canasta/CanastaUtils.php index 22087cad..50fb9c9b 100644 --- a/_sources/canasta/CanastaUtils.php +++ b/_sources/canasta/CanastaUtils.php @@ -22,3 +22,33 @@ function cfLoadSkin( $skinName ) { echo "The following skin was loaded with cfLoadSkin, but needs to be loaded with wfLoadSkin instead: $skinName"; die(); } + +/** + * Not exactly a utility function, but - show a warning to users if $wgSMTP is not set. + */ +$wgHooks['SiteNoticeAfter'][] = function ( &$siteNotice, Skin $skin ) { + global $wgSMTP, $wgEnableEmail, $wgEnableUserEmail; + + if ( !$wgEnableEmail || $wgSMTP ) { + return; + } + $title = $skin->getTitle(); + if ( !$title->isSpecialPage() ) { + return; + } + $specialPage = MediaWiki\MediaWikiServices::getInstance() + ->getSpecialPageFactory() + ->getPage( $title->getText() ); + $canonicalName = $specialPage->getName(); + // Only display this warning for pages that could result in an email getting sent. + $specialPagesWithEmail = [ 'Preferences', 'CreateAccount' ]; + if ( $wgEnableUserEmail ) { + $specialPagesWithEmail[] = 'Emailuser'; + } + if ( !in_array( $canonicalName, $specialPagesWithEmail ) ) { + return; + } + + $warningText = 'Please note that mailing does not currently work on this wiki, because Canasta requires $wgSMTP to be set in order to send emails.'; + $siteNotice .= Html::warningBox( '' . $warningText . '' ); +}; From 3b2c4ebd8cc30fb8951cefc02e55ee9e035f2221 Mon Sep 17 00:00:00 2001 From: Yaron Koren Date: Sun, 22 Jan 2023 17:31:00 -0500 Subject: [PATCH 32/67] Add six extensions (#207) * Add six extensions DeleteBatch, Mermaid, SemanticDependencyUpdater, Title Icon, WatchAnalytics and WhosOnline. A partial or complete fix for #192, and a fix for #177. * Update composer.canasta.json * Add missing comma * Add note about Mermaid to Dockerfile --- Dockerfile | 26 +++++++++++++++++++++++--- _sources/configs/composer.canasta.json | 1 + 2 files changed, 24 insertions(+), 3 deletions(-) diff --git a/Dockerfile b/Dockerfile index d824ffbc..dd45dc06 100644 --- a/Dockerfile +++ b/Dockerfile @@ -124,9 +124,9 @@ RUN set -x; \ # PdfHandler, Poem, Renameuser, Replace Text, Scribunto, SecureLinkFixer, SpamBlacklist, SyntaxHighlight, TemplateData, # TextExtracts, TitleBlacklist, VisualEditor, WikiEditor. # The following extensions are downloaded via Composer and also do not need to be downloaded here: Bootstrap, -# BootstrapComponents, Maps, Semantic Breadcrumb Links, Semantic Compound Queries, Semantic Extra Special Properties, -# Semantic MediaWiki (along with all its helper library extensions, like DataValues), Semantic Result Formats, Semantic -# Scribunto, SimpleBatchUpload, SubPageList. +# BootstrapComponents, Maps, Mermaid, Semantic Breadcrumb Links, Semantic Compound Queries, Semantic Extra Special +# Properties, Semantic MediaWiki (along with all its helper library extensions, like DataValues), Semantic Result +# Formats, Semantic Scribunto, SimpleBatchUpload, SubPageList. RUN set -x; \ cd $MW_HOME/extensions \ # AdminLinks @@ -213,6 +213,10 @@ RUN set -x; \ && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/DataTransfer $MW_HOME/extensions/DataTransfer \ && cd $MW_HOME/extensions/DataTransfer \ && git checkout -q 2f9f949f71f0bb7d1bd8b6b97c795b9428bb1c71 \ + # DeleteBatch + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/DeleteBatch $MW_HOME/extensions/DeleteBatch \ + && cd $MW_HOME/extensions/DeleteBatch \ + && git checkout -q 82078d60fc59a718f429ddebe5e99de8a8734413 \ # Description2 && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Description2 $MW_HOME/extensions/Description2 \ && cd $MW_HOME/extensions/Description2 \ @@ -425,6 +429,10 @@ RUN set -x; \ && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/SaveSpinner $MW_HOME/extensions/SaveSpinner \ && cd $MW_HOME/extensions/SaveSpinner \ && git checkout -q 1e819e2fff7fad6999bafe71d866c3af50836c42 \ + # SemanticDependencyUpdater (v. 2.0.2) + && git clone --single-branch -b master https://github.com/gesinn-it/SemanticDependencyUpdater $MW_HOME/extensions/SemanticDependencyUpdater \ + && cd $MW_HOME/extensions/SemanticDependencyUpdater \ + && git checkout -q 389e34c4d4249d27b283a8a29c654fb708b8b294 \ # SemanticDrilldown && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/SemanticDrilldown $MW_HOME/extensions/SemanticDrilldown \ && cd $MW_HOME/extensions/SemanticDrilldown \ @@ -469,6 +477,10 @@ RUN set -x; \ && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/TinyMCE $MW_HOME/extensions/TinyMCE \ && cd $MW_HOME/extensions/TinyMCE \ && git checkout -q 06436ec3a53c6cd53c458e4e8ab3ec8d1a23029b \ + # TitleIcon + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/TitleIcon $MW_HOME/extensions/TitleIcon \ + && cd $MW_HOME/extensions/TitleIcon \ + && git checkout -q 7c6c83f4859642542393612ad961a258378e0cac \ # UniversalLanguageSelector && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/UniversalLanguageSelector $MW_HOME/extensions/UniversalLanguageSelector \ && cd $MW_HOME/extensions/UniversalLanguageSelector \ @@ -505,10 +517,18 @@ RUN set -x; \ && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/VoteNY $MW_HOME/extensions/VoteNY \ && cd $MW_HOME/extensions/VoteNY \ && git checkout -q 11c103f4b9167a8d8d5e850d8a781c6f49b249c1 \ + # WatchAnalytics (v. 3.2.0) + && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/WatchAnalytics $MW_HOME/extensions/WatchAnalytics \ + && cd $MW_HOME/extensions/WatchAnalytics \ + && git checkout -q a5751cb6e066eaf9b151b1b86857cafe254f7feb \ # WhoIsWatching && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/WhoIsWatching $MW_HOME/extensions/WhoIsWatching \ && cd $MW_HOME/extensions/WhoIsWatching \ && git checkout -q 836a31018e26ab7c993088c4cca31a89efec2ee5 \ + # WhosOnline + && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/WhosOnline $MW_HOME/extensions/WhosOnline \ + && cd $MW_HOME/extensions/WhosOnline \ + && git checkout -q bb1765d2eb5c88ca10dc8a0be19f35fcffdccdae \ # Widgets && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Widgets $MW_HOME/extensions/Widgets \ && cd $MW_HOME/extensions/Widgets \ diff --git a/_sources/configs/composer.canasta.json b/_sources/configs/composer.canasta.json index 3a14e4b2..beaa7ad1 100644 --- a/_sources/configs/composer.canasta.json +++ b/_sources/configs/composer.canasta.json @@ -3,6 +3,7 @@ "elasticsearch/elasticsearch": "^7.11.0", "mediawiki/chameleon-skin": "^3.4.1", "mediawiki/maps": "8.0.0", + "mediawiki/mermaid": "~3.1", "mediawiki/semantic-media-wiki": "^4.0.0" }, "extra": { From bd6c2aa68a76a6d81015e131548a589aad9c5170 Mon Sep 17 00:00:00 2001 From: = <=> Date: Sun, 5 Feb 2023 09:25:35 -0500 Subject: [PATCH 33/67] add comments for CIDR ranges --- _sources/canasta/CanastaDefaultSettings.php | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/_sources/canasta/CanastaDefaultSettings.php b/_sources/canasta/CanastaDefaultSettings.php index 3ea1ed7e..b4c69f56 100644 --- a/_sources/canasta/CanastaDefaultSettings.php +++ b/_sources/canasta/CanastaDefaultSettings.php @@ -62,12 +62,13 @@ $wgSVGConverter = 'rsvg'; # Docker specific setup +# Exclude all private IP ranges # see https://www.mediawiki.org/wiki/Manual:$wgCdnServersNoPurge $wgUseCdn = true; $wgCdnServersNoPurge = []; -$wgCdnServersNoPurge[] = '172.16.0.0/12'; -$wgCdnServersNoPurge[] = '192.168.0.0/16'; -$wgCdnServersNoPurge[] = '10.0.0.0/8'; +$wgCdnServersNoPurge[] = 10.0.0.0/8; // 10.0.0.0 – 10.255.255.255 +$wgCdnServersNoPurge[] = 172.16.0.0/12; // 172.16.0.0 – 172.31.255.255 +$wgCdnServersNoPurge[] = 192.168.0.0/16; // 192.168.0.0 – 192.168.255.255 # Include user defined LocalSettings.php file require_once "$canastaLocalSettingsFilePath"; From 83306b06ae2e10d5393e86760a1bb61cc2dc2158 Mon Sep 17 00:00:00 2001 From: Yaron Koren Date: Thu, 16 Feb 2023 16:56:43 -0500 Subject: [PATCH 34/67] Update some extensions' versions This was mostly done to get in some MW 1.39 compatibility fixes - except for WatchAnalytics, where it was just done for general improvements. --- Dockerfile | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/Dockerfile b/Dockerfile index dd45dc06..50fc30e5 100644 --- a/Dockerfile +++ b/Dockerfile @@ -161,10 +161,10 @@ RUN set -x; \ && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/BreadCrumbs2 $MW_HOME/extensions/BreadCrumbs2 \ && cd $MW_HOME/extensions/BreadCrumbs2 \ && git checkout -q d53357a6839e94800a617de4fc451b6c64d0a1c8 \ - # Cargo (v. 3.3.1) + # Cargo (v. 3.4.1) && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/Cargo $MW_HOME/extensions/Cargo \ && cd $MW_HOME/extensions/Cargo \ - && git checkout -q dac6b0da0e3cb5a4226601ebccf1689dbaa6bec7 \ + && git checkout -q 04bfe84ef4dc806eab0ec52b361a78542d799474 \ # CharInsert && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/CharInsert $MW_HOME/extensions/CharInsert \ && cd $MW_HOME/extensions/CharInsert \ @@ -361,10 +361,10 @@ RUN set -x; \ && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/MediaUploader $MW_HOME/extensions/MediaUploader \ && cd $MW_HOME/extensions/MediaUploader \ && git checkout -q 1edd91c506c1c0319e7b9a3e71d639130760b1fd \ - # MintyDocs - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/MintyDocs $MW_HOME/extensions/MintyDocs \ + # MintyDocs (1.0) + && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/MintyDocs $MW_HOME/extensions/MintyDocs \ && cd $MW_HOME/extensions/MintyDocs \ - && git checkout -q 7d5562dd5564eeb4c3b907a9eecd84a2f7654dd1 \ + && git checkout -q 4496e33ce71d2c364b16599619c961a1a330bf14 \ # MobileFrontend && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/MobileFrontend $MW_HOME/extensions/MobileFrontend \ && cd $MW_HOME/extensions/MobileFrontend \ @@ -397,10 +397,10 @@ RUN set -x; \ && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/PageExchange $MW_HOME/extensions/PageExchange \ && cd $MW_HOME/extensions/PageExchange \ && git checkout -q 28482410564e38d2b97ab7321e99c4281c6e5877 \ - # PageForms (v. 5.5.1) + # PageForms (v. 5.6) && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/PageForms $MW_HOME/extensions/PageForms \ && cd $MW_HOME/extensions/PageForms \ - && git checkout -q 74ebc5de5d1b515aeb59c848c3a9e3425da13114 \ + && git checkout -q d9b0e47a83d951c585f95c97ea10ea8be95adec9 \ # PluggableAuth && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/PluggableAuth $MW_HOME/extensions/PluggableAuth \ && cd $MW_HOME/extensions/PluggableAuth \ @@ -520,7 +520,7 @@ RUN set -x; \ # WatchAnalytics (v. 3.2.0) && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/WatchAnalytics $MW_HOME/extensions/WatchAnalytics \ && cd $MW_HOME/extensions/WatchAnalytics \ - && git checkout -q a5751cb6e066eaf9b151b1b86857cafe254f7feb \ + && git checkout -q f6e4d07a93baf502358ce0af01c0ac7e59cc6f4b \ # WhoIsWatching && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/WhoIsWatching $MW_HOME/extensions/WhoIsWatching \ && cd $MW_HOME/extensions/WhoIsWatching \ From 2b95bcca0cd682ec18b19eede2142b0ba3336404 Mon Sep 17 00:00:00 2001 From: Jeffrey Wang Date: Fri, 17 Feb 2023 20:45:37 -0600 Subject: [PATCH 35/67] Addressed PR comments and updated Header Tabs --- Dockerfile | 6 +++--- _sources/configs/composer.canasta.json | 5 ++--- 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/Dockerfile b/Dockerfile index 50fc30e5..98dff913 100644 --- a/Dockerfile +++ b/Dockerfile @@ -4,7 +4,7 @@ LABEL maintainers="" LABEL org.opencontainers.image.source=https://github.com/CanastaWiki/Canasta ENV MW_VERSION=REL1_39 \ - MW_CORE_VERSION=1.39.0 \ + MW_CORE_VERSION=1.39.1 \ WWW_ROOT=/var/www/mediawiki \ MW_HOME=/var/www/mediawiki/w \ MW_ORIGIN_FILES=/mw_origin_files \ @@ -201,7 +201,7 @@ RUN set -x; \ && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/ContactPage $MW_HOME/extensions/ContactPage \ && cd $MW_HOME/extensions/ContactPage \ && git checkout -q f509796056ae1fc597b6e3c3c268fac35bf66636 \ - # ContributionScores + # ContributionScores && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/ContributionScores $MW_HOME/extensions/ContributionScores \ && cd $MW_HOME/extensions/ContributionScores \ && git checkout -q e307850555ef313f623dde6e2f1d5d2a43663730 \ @@ -292,7 +292,7 @@ RUN set -x; \ # HeaderTabs && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/HeaderTabs $MW_HOME/extensions/HeaderTabs \ && cd $MW_HOME/extensions/HeaderTabs \ - && git checkout -q b3d96193f3cacef5ac2637f197f0b2822597925e \ + && git checkout -q 42aaabf1deeb0a228fc99e578ff7ec925e560dd7 \ # HTMLTags && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/HTMLTags $MW_HOME/extensions/HTMLTags \ && cd $MW_HOME/extensions/HTMLTags \ diff --git a/_sources/configs/composer.canasta.json b/_sources/configs/composer.canasta.json index beaa7ad1..8b1e7964 100644 --- a/_sources/configs/composer.canasta.json +++ b/_sources/configs/composer.canasta.json @@ -1,10 +1,9 @@ { "require": { - "elasticsearch/elasticsearch": "^7.11.0", "mediawiki/chameleon-skin": "^3.4.1", - "mediawiki/maps": "8.0.0", + "mediawiki/maps": "10.0.0", "mediawiki/mermaid": "~3.1", - "mediawiki/semantic-media-wiki": "^4.0.0" + "mediawiki/semantic-media-wiki": "4.0.2" }, "extra": { "merge-plugin": { From b66d51d46093fee23a91e7470e1fea740b5d56f2 Mon Sep 17 00:00:00 2001 From: Jeffrey Wang Date: Fri, 17 Feb 2023 20:59:01 -0600 Subject: [PATCH 36/67] Update release notes --- RELEASE_NOTES.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/RELEASE_NOTES.md b/RELEASE_NOTES.md index 403aad52..4fc48d29 100644 --- a/RELEASE_NOTES.md +++ b/RELEASE_NOTES.md @@ -7,4 +7,5 @@ Canasta version history: - 1.1.2 - July 12, 2022 - update MediaWiki version to 1.35.7; add default setting of $wgServer; add CookieWarning extension; update CommentStreams, Echo and EmbedVideo extensions; remove HeadScript extension; add poppler-utils package for PDF rendering - 1.2.0 - October 2, 2022 - update MediaWiki version to 1.35.8; remove cfLoadExtension() and cfLoadSkin() functionality in favor of symlink-based approach; add displayWikiInfo.php script; make use of gateway.docker.internal to detect host address - 1.2.1 - November 25, 2022 - add AArch64 support; update SimpleBatchUpload extension -- 1.2.2 - December 22, 2022 - Fix installation of EmailAuthorization extension; fix web installer to also install Boostrap extension if Chameleon skin gets installed; add MW_MAP_DOMAIN_TO_DOCKER_GATEWAY as an environment variable (set to true by default); remove patches made unnecessary by cfLoad... removal \ No newline at end of file +- 1.2.2 - December 22, 2022 - Fix installation of EmailAuthorization extension; fix web installer to also install Boostrap extension if Chameleon skin gets installed; add MW_MAP_DOMAIN_TO_DOCKER_GATEWAY as an environment variable (set to true by default); remove patches made unnecessary by cfLoad... removal +- 1.3.0 - February 17, 2023 - update MediaWiki version to 1.39.0; update all extensions to a compatible version (in most cases, using the REL1_39 Git branch); add the extensions AbuseFilter, DeleteBatch, MediaUploader, Mermaid, SemanticDependencyUpdater, TemplateWizard, Title Icon, UserPageViewTracker, WatchAnalytics, WhosOnline; remove the extensions DiscussionTools, LocalisationUpdate; add the skins MinervaNeue, Vector 2022; add header warning to email-related special pages if $wgSMTP is not set \ No newline at end of file From 3fd9a2b790c8de902a9b14ff9da12a1664ec50c7 Mon Sep 17 00:00:00 2001 From: Jeffrey Wang Date: Fri, 17 Feb 2023 22:42:04 -0600 Subject: [PATCH 37/67] Adding back extensions to Composer --- Dockerfile | 4 ++-- _sources/configs/composer.canasta.json | 10 +++++++++- _sources/patches/core-local-settings-generator.patch | 3 ++- 3 files changed, 13 insertions(+), 4 deletions(-) diff --git a/Dockerfile b/Dockerfile index 9e542f16..0b3b565d 100644 --- a/Dockerfile +++ b/Dockerfile @@ -286,8 +286,8 @@ RUN set -x; \ && git clone https://github.com/enterprisemediawiki/HeaderFooter.git $MW_HOME/extensions/HeaderFooter \ && cd $MW_HOME/extensions/HeaderFooter \ && git checkout -q eee7d2c1a3373c7d6b326fd460e5d4859dd22c40 \ - # HeaderTabs - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/HeaderTabs $MW_HOME/extensions/HeaderTabs \ + # HeaderTabs (v2.2) + && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/HeaderTabs $MW_HOME/extensions/HeaderTabs \ && cd $MW_HOME/extensions/HeaderTabs \ && git checkout -q 42aaabf1deeb0a228fc99e578ff7ec925e560dd7 \ # HTMLTags diff --git a/_sources/configs/composer.canasta.json b/_sources/configs/composer.canasta.json index 8b1e7964..0cd446db 100644 --- a/_sources/configs/composer.canasta.json +++ b/_sources/configs/composer.canasta.json @@ -3,7 +3,15 @@ "mediawiki/chameleon-skin": "^3.4.1", "mediawiki/maps": "10.0.0", "mediawiki/mermaid": "~3.1", - "mediawiki/semantic-media-wiki": "4.0.2" + "mediawiki/semantic-media-wiki": "4.0.2", + "mediawiki/semantic-result-formats": "4.0.1", + "mediawiki/semantic-breadcrumb-links": "2.1.x-dev", + "mediawiki/semantic-compound-queries": "~2.2", + "mediawiki/semantic-extra-special-properties": "3.0.1", + "mediawiki/semantic-scribunto": "2.2.0", + "mediawiki/simple-batch-upload": "^1.0", + "mediawiki/bootstrap-components": "^5.0", + "mediawiki/sub-page-list": "2.0.2" }, "extra": { "merge-plugin": { diff --git a/_sources/patches/core-local-settings-generator.patch b/_sources/patches/core-local-settings-generator.patch index a7135199..5c81e273 100644 --- a/_sources/patches/core-local-settings-generator.patch +++ b/_sources/patches/core-local-settings-generator.patch @@ -1,8 +1,9 @@ --- a/includes/installer/LocalSettingsGenerator.php +++ b/includes/installer/LocalSettingsGenerator.php -@@ -48,6 +48,15 @@ class LocalSettingsGenerator { +@@ -51,6 +51,15 @@ $this->skins = $installer->getVar( '_Skins' ); $this->IP = $installer->getVar( 'IP' ); + + // Patch for Canasta - if the user is enabling the Chameleon + // skin (likely, since all skins are selected by default), make + // sure the Bootstrap skin is enabled as well, to avoid a From dfae019bba39bed69bf536c2d27979e45f42ced0 Mon Sep 17 00:00:00 2001 From: Jeffrey Wang Date: Fri, 17 Feb 2023 22:56:43 -0600 Subject: [PATCH 38/67] Bump Chameleon version --- _sources/configs/composer.canasta.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/_sources/configs/composer.canasta.json b/_sources/configs/composer.canasta.json index 0cd446db..4f69c169 100644 --- a/_sources/configs/composer.canasta.json +++ b/_sources/configs/composer.canasta.json @@ -1,6 +1,6 @@ { "require": { - "mediawiki/chameleon-skin": "^3.4.1", + "mediawiki/chameleon-skin": "~4.0", "mediawiki/maps": "10.0.0", "mediawiki/mermaid": "~3.1", "mediawiki/semantic-media-wiki": "4.0.2", From 3c2285d84963a9c56ff73b528843b8cfc790b697 Mon Sep 17 00:00:00 2001 From: Jeffrey Wang Date: Fri, 17 Feb 2023 23:10:43 -0600 Subject: [PATCH 39/67] adding back Google Analytics Metrics --- _sources/configs/composer.canasta.json | 1 + 1 file changed, 1 insertion(+) diff --git a/_sources/configs/composer.canasta.json b/_sources/configs/composer.canasta.json index 4f69c169..ea8b15e6 100644 --- a/_sources/configs/composer.canasta.json +++ b/_sources/configs/composer.canasta.json @@ -25,6 +25,7 @@ "extensions/AntiSpoof/composer.json", "extensions/TemplateStyles/composer.json", "extensions/Widgets/composer.json", + "extensions/GoogleAnalyticsMetrics/composer.json", "extensions/OpenIDConnect/composer.json", "extensions/WSOAuth/composer.json" ] From 3193ebdb530bb332e587469340276b05380b84ad Mon Sep 17 00:00:00 2001 From: Yaron Koren Date: Sat, 18 Feb 2023 12:22:41 -0500 Subject: [PATCH 40/67] Update Approved Revs and SimpleBatchUpload --- Dockerfile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index 0b3b565d..22354d14 100644 --- a/Dockerfile +++ b/Dockerfile @@ -142,10 +142,10 @@ RUN set -x; \ && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/AntiSpoof $MW_HOME/extensions/AntiSpoof \ && cd $MW_HOME/extensions/AntiSpoof \ && git checkout -q 01cf89a678d5bab6610d24e07d3534356a5880cb \ - # ApprovedRevs (v. 1.8) + # ApprovedRevs (v. 1.8.1) && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/ApprovedRevs $MW_HOME/extensions/ApprovedRevs \ && cd $MW_HOME/extensions/ApprovedRevs \ - && git checkout -q 6e9c957f2f7951f19054ecae8745e55c0425941f \ + && git checkout -q a8cb4bd840465a7db1e10654a0969cfc961d8428 \ # Arrays && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Arrays $MW_HOME/extensions/Arrays \ && cd $MW_HOME/extensions/Arrays \ From f879008fe7416aa6c2bc859b3bc205cc70a14f9b Mon Sep 17 00:00:00 2001 From: Yaron Koren Date: Sat, 18 Feb 2023 12:24:15 -0500 Subject: [PATCH 41/67] Update composer.canasta.json --- _sources/configs/composer.canasta.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/_sources/configs/composer.canasta.json b/_sources/configs/composer.canasta.json index ea8b15e6..ecc68dd5 100644 --- a/_sources/configs/composer.canasta.json +++ b/_sources/configs/composer.canasta.json @@ -9,7 +9,7 @@ "mediawiki/semantic-compound-queries": "~2.2", "mediawiki/semantic-extra-special-properties": "3.0.1", "mediawiki/semantic-scribunto": "2.2.0", - "mediawiki/simple-batch-upload": "^1.0", + "mediawiki/simple-batch-upload": "1.8.2", "mediawiki/bootstrap-components": "^5.0", "mediawiki/sub-page-list": "2.0.2" }, From 4dbb2ca3538fec834021b3890ae14ac3e1793d6f Mon Sep 17 00:00:00 2001 From: Jeffrey Wang Date: Sat, 18 Feb 2023 23:43:27 -0600 Subject: [PATCH 42/67] Disable DB checking if using remote DB --- _sources/scripts/run-apache.sh | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/_sources/scripts/run-apache.sh b/_sources/scripts/run-apache.sh index 9b76e352..c440dccb 100755 --- a/_sources/scripts/run-apache.sh +++ b/_sources/scripts/run-apache.sh @@ -18,6 +18,17 @@ isTrue() { esac } +isFalse() { + case $1 in + "True" | "TRUE" | "true" | 1) + return 1 + ;; + *) + return 0 + ;; + esac +} + dir_is_writable() { # Use -L to get information about the target of a symlink, # not the link itself, as pointed out in the comments @@ -162,7 +173,9 @@ sitemapgen() { } waitdatabase() { - /wait-for-it.sh -t 60 db:3306 + if isFalse "$USE_EXTERNAL_DB"; then + /wait-for-it.sh -t 60 db:3306 + fi } #waitelastic() { From 34f00842ef6c4142430f75c1454cde1ca3864e3c Mon Sep 17 00:00:00 2001 From: Yaron Koren Date: Wed, 22 Feb 2023 16:40:23 -0500 Subject: [PATCH 43/67] Update Widgets version --- Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 22354d14..038924a3 100644 --- a/Dockerfile +++ b/Dockerfile @@ -529,7 +529,7 @@ RUN set -x; \ # Widgets && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Widgets $MW_HOME/extensions/Widgets \ && cd $MW_HOME/extensions/Widgets \ - && git checkout -q 583c4f5e1829d2f78fb4a6e1f22bc9de4cf4d3a8 \ + && git checkout -q 197d429f971b2aebbce29b7a91a194e1f8181e64 \ # WikiForum && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/WikiForum $MW_HOME/extensions/WikiForum \ && cd $MW_HOME/extensions/WikiForum \ From 22060bf35fc6535c1b088e8af4a699abe13d243f Mon Sep 17 00:00:00 2001 From: Yaron Koren Date: Thu, 2 Mar 2023 11:10:25 -0500 Subject: [PATCH 44/67] Add monitoring for extension and skins modifications (patch by @gitmapd) (#215) * Create monitor-directories.sh * Update Dockerfile * Update run-apache.sh --- Dockerfile | 1 + _sources/scripts/monitor-directories.sh | 37 +++++++++++++++++++++++++ _sources/scripts/run-apache.sh | 5 ++++ 3 files changed, 43 insertions(+) create mode 100644 _sources/scripts/monitor-directories.sh diff --git a/Dockerfile b/Dockerfile index 038924a3..22d58576 100644 --- a/Dockerfile +++ b/Dockerfile @@ -21,6 +21,7 @@ RUN set x; \ && aptitude -y upgrade \ && aptitude install -y \ git \ + inotify-tools \ apache2 \ software-properties-common \ gpg \ diff --git a/_sources/scripts/monitor-directories.sh b/_sources/scripts/monitor-directories.sh new file mode 100644 index 00000000..730e5b57 --- /dev/null +++ b/_sources/scripts/monitor-directories.sh @@ -0,0 +1,37 @@ +#!/usr/bin/env bash +set -x + +userexts="$MW_HOME/user-extensions" +extensions="$MW_HOME/extensions" +canexts="$MW_HOME/canasta-extensions" + +userskins="$MW_HOME/user-skins" +skins="$MW_HOME/skins" +canskins="$MW_HOME/canasta-skins" + +# - Detects activity changes inside user-extensions and user-skins. +# - Adds symlinks from the those folders to the appropriate correspondent folders, user-extensions to extensions and user-skins to skins. +# - As a fallback, the moment the extension is removed or moved from user-extensions it will revert back by adding a symlink to the extension +# located in canasta-extensions. + +inotifywait -m -e create,moved_to,delete,moved_from --format '%e:%f%0' -- "$userexts" | + while IFS=: read -r event file; do + case $event in + CREATE,ISDIR|MOVED_TO,ISDIR) + ln -rsft "$extensions" -- "$userexts"/"$file" ;; + DELETE,ISDIR|MOVED_FROM,ISDIR) + echo "event: ${event} file: ${file}"; + ln -rsft "$extensions" -- "$canexts"/"$file" || rm -- "$file"; + esac + done + +inotifywait -m -e create,moved_to,delete,moved_from --format '%e:%f%0' -- "$userskins" | + while IFS=: read -r event file; do + case $event in + CREATE,ISDIR|MOVED_TO,ISDIR) + ln -rsft skins -- "$userskins"/"$file" ;; + DELETE,ISDIR|MOVED_FROM,ISDIR) + echo "event: ${event} file: ${file}"; + ln -rsft skins -- "$canskins"/"$file" || rm -- "$file"; + esac + done diff --git a/_sources/scripts/run-apache.sh b/_sources/scripts/run-apache.sh index c440dccb..99558a6a 100755 --- a/_sources/scripts/run-apache.sh +++ b/_sources/scripts/run-apache.sh @@ -202,6 +202,10 @@ check_mount_points () { fi } +inotifywait() { + runuser -c /monitor-directories.sh -s /bin/bash "$WWW_USER" +} + # Wait db waitdatabase @@ -222,6 +226,7 @@ echo "Starting services..." jobrunner & transcoder & sitemapgen & +inotifywait & ############### Run Apache ############### # Make sure we're not confused by old, incompletely-shutdown httpd From e54c694eb575e796880d80808ce4e75dcaf48a77 Mon Sep 17 00:00:00 2001 From: Yaron Koren Date: Fri, 3 Mar 2023 09:33:40 -0500 Subject: [PATCH 45/67] Create create-symlinks.sh --- _sources/scripts/create-symlinks.sh | 39 +++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) create mode 100644 _sources/scripts/create-symlinks.sh diff --git a/_sources/scripts/create-symlinks.sh b/_sources/scripts/create-symlinks.sh new file mode 100644 index 00000000..6514627b --- /dev/null +++ b/_sources/scripts/create-symlinks.sh @@ -0,0 +1,39 @@ +#!/bin/bash + +echo "Symlinking bundled extensions..." +for bundled_extension_path in $(find $MW_HOME/canasta-extensions/ -maxdepth 1 -mindepth 1 -type d) +do + bundled_extension_id=$(basename $bundled_extension_path) + ln -s $MW_HOME/canasta-extensions/$bundled_extension_id/ $MW_HOME/extensions/$bundled_extension_id +done + +echo "Symlinking bundled skins..." +for bundled_skin_path in $(find $MW_HOME/canasta-skins/ -maxdepth 1 -mindepth 1 -type d) +do + bundled_skin_id=$(basename $bundled_skin_path) + ln -s $MW_HOME/canasta-skins/$bundled_skin_id/ $MW_HOME/skins/$bundled_skin_id +done + +echo "Symlinking user extensions and overwriting any redundant bundled extensions..." +for user_extension_path in $(find $MW_HOME/user-extensions/ -maxdepth 1 -mindepth 1 -type d) +do + user_extension_id=$(basename $user_extension_path) + extension_symlink_path="$MW_HOME/extensions/$user_extension_id" + if [[ -e "$extension_symlink_path" ]] + then + rm "$extension_symlink_path" + fi + ln -s $MW_HOME/user-extensions/$user_extension_id/ $MW_HOME/extensions/$user_extension_id +done + +echo "Symlinking user skins and overwriting any redundant bundled skins..." +for user_skin_path in $(find $MW_HOME/user-skins/ -maxdepth 1 -mindepth 1 -type d) +do + user_skin_id=$(basename $user_skin_path) + skin_symlink_path="$MW_HOME/skins/$user_skin_id" + if [[ -e "$skin_symlink_path" ]] + then + rm "$skin_symlink_path" + fi + ln -s $MW_HOME/user-skins/$user_skin_id/ $MW_HOME/skins/$user_skin_id +done From a83e5046d942498ec6567f06d3f98ae70a5b8501 Mon Sep 17 00:00:00 2001 From: Yaron Koren Date: Fri, 3 Mar 2023 09:37:09 -0500 Subject: [PATCH 46/67] Update run-apache.sh --- _sources/scripts/run-apache.sh | 39 +--------------------------------- 1 file changed, 1 insertion(+), 38 deletions(-) diff --git a/_sources/scripts/run-apache.sh b/_sources/scripts/run-apache.sh index c440dccb..063abaae 100755 --- a/_sources/scripts/run-apache.sh +++ b/_sources/scripts/run-apache.sh @@ -55,45 +55,8 @@ dir_is_writable() { return 1 } -prepare_extensions_skins_symlinks() { - echo "Symlinking bundled extensions..." - for bundled_extension_path in $(find $MW_HOME/canasta-extensions/ -maxdepth 1 -mindepth 1 -type d) - do - bundled_extension_id=$(basename $bundled_extension_path) - ln -s $MW_HOME/canasta-extensions/$bundled_extension_id/ $MW_HOME/extensions/$bundled_extension_id - done - echo "Symlinking bundled skins..." - for bundled_skin_path in $(find $MW_HOME/canasta-skins/ -maxdepth 1 -mindepth 1 -type d) - do - bundled_skin_id=$(basename $bundled_skin_path) - ln -s $MW_HOME/canasta-skins/$bundled_skin_id/ $MW_HOME/skins/$bundled_skin_id - done - echo "Symlinking user extensions and overwriting any redundant bundled extensions..." - for user_extension_path in $(find $MW_HOME/user-extensions/ -maxdepth 1 -mindepth 1 -type d) - do - user_extension_id=$(basename $user_extension_path) - extension_symlink_path="$MW_HOME/extensions/$user_extension_id" - if [[ -e "$extension_symlink_path" ]] - then - rm "$extension_symlink_path" - fi - ln -s $MW_HOME/user-extensions/$user_extension_id/ $MW_HOME/extensions/$user_extension_id - done - echo "Symlinking user skins and overwriting any redundant bundled skins..." - for user_skin_path in $(find $MW_HOME/user-skins/ -maxdepth 1 -mindepth 1 -type d) - do - user_skin_id=$(basename $user_skin_path) - skin_symlink_path="$MW_HOME/skins/$user_skin_id" - if [[ -e "$skin_symlink_path" ]] - then - rm "$skin_symlink_path" - fi - ln -s $MW_HOME/user-skins/$user_skin_id/ $MW_HOME/skins/$user_skin_id - done -} - # Symlink all extensions and skins (both bundled and user) -prepare_extensions_skins_symlinks +/create-symlinks.sh # Soft sync contents from $MW_ORIGIN_FILES directory to $MW_VOLUME # The goal of this operation is to copy over all the files generated From 794e24de6b5f10d3837017bd29f5306e1af458af Mon Sep 17 00:00:00 2001 From: Ayman161803 Date: Tue, 7 Mar 2023 14:01:59 +0530 Subject: [PATCH 47/67] chore: switch to github mirrors for cloning Signed-off-by: Ayman161803 --- Dockerfile | 204 ++++++++++++++++++++++++++--------------------------- 1 file changed, 102 insertions(+), 102 deletions(-) diff --git a/Dockerfile b/Dockerfile index 038924a3..e0c5e3a2 100644 --- a/Dockerfile +++ b/Dockerfile @@ -84,7 +84,7 @@ FROM base as source # MediaWiki core RUN set -x; \ - git clone --depth 1 -b $MW_CORE_VERSION https://gerrit.wikimedia.org/r/mediawiki/core.git $MW_HOME \ + git clone --depth 1 -b $MW_CORE_VERSION https://github.com/wikimedia/mediawiki $MW_HOME \ && cd $MW_HOME \ && git submodule update --init --recursive @@ -94,7 +94,7 @@ RUN set -x; \ RUN set -x; \ cd $MW_HOME/skins \ # CologneBlue - && git clone -b $MW_VERSION --single-branch https://gerrit.wikimedia.org/r/mediawiki/skins/CologneBlue $MW_HOME/skins/CologneBlue \ + && git clone -b $MW_VERSION --single-branch https://github.com/wikimedia/mediawiki-skins-CologneBlue $MW_HOME/skins/CologneBlue \ && cd $MW_HOME/skins/CologneBlue \ && git checkout -q 4d588eb78d7e64e574f631c5897579537305437d \ # MinervaNeue @@ -102,7 +102,7 @@ RUN set -x; \ #&& cd $MW_HOME/skins/MinervaNeue \ #&& git checkout -q e4741ff2c4375c2befee0d9f350aff6eb6e1a4da \ # Modern - && git clone -b $MW_VERSION --single-branch https://gerrit.wikimedia.org/r/mediawiki/skins/Modern $MW_HOME/skins/Modern \ + && git clone -b $MW_VERSION --single-branch https://github.com/wikimedia/mediawiki-skins-Modern $MW_HOME/skins/Modern \ && cd $MW_HOME/skins/Modern \ && git checkout -q fb6c2831b5f150e9b82d98d661710695a2d0f8f2 \ # Pivot @@ -110,7 +110,7 @@ RUN set -x; \ && cd $MW_HOME/skins/pivot \ && git checkout -q d79af7514347eb5272936243d4013118354c85c1 \ # Refreshed - && git clone -b $MW_VERSION --single-branch https://gerrit.wikimedia.org/r/mediawiki/skins/Refreshed $MW_HOME/skins/Refreshed \ + && git clone -b $MW_VERSION --single-branch https://github.com/wikimedia/mediawiki-skins-Refreshed $MW_HOME/skins/Refreshed \ && cd $MW_HOME/skins/Refreshed \ && git checkout -q 86f33620f25335eb62289aa18d342ff3b980d8b8 @@ -127,123 +127,123 @@ RUN set -x; \ RUN set -x; \ cd $MW_HOME/extensions \ # AdminLinks - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/AdminLinks $MW_HOME/extensions/AdminLinks \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-AdminLinks $MW_HOME/extensions/AdminLinks \ && cd $MW_HOME/extensions/AdminLinks \ && git checkout -q ad7805941ee29378484d1ef3595041f7d2c15913 \ # AdvancedSearch - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/AdvancedSearch $MW_HOME/extensions/AdvancedSearch \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-AdvancedSearch $MW_HOME/extensions/AdvancedSearch \ && cd $MW_HOME/extensions/AdvancedSearch \ && git checkout -q 1a44eafc93a17938333b74a37cb4deff2192e50a \ # AJAXPoll - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/AJAXPoll $MW_HOME/extensions/AJAXPoll \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-AJAXPoll $MW_HOME/extensions/AJAXPoll \ && cd $MW_HOME/extensions/AJAXPoll \ && git checkout -q 8429d8d4cba5be6df04e3fec17b0daabbf10cfa7 \ # AntiSpoof - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/AntiSpoof $MW_HOME/extensions/AntiSpoof \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-AntiSpoof $MW_HOME/extensions/AntiSpoof \ && cd $MW_HOME/extensions/AntiSpoof \ && git checkout -q 01cf89a678d5bab6610d24e07d3534356a5880cb \ # ApprovedRevs (v. 1.8.1) - && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/ApprovedRevs $MW_HOME/extensions/ApprovedRevs \ + && git clone --single-branch -b master https://github.com/wikimedia/mediawiki-extensions-ApprovedRevs $MW_HOME/extensions/ApprovedRevs \ && cd $MW_HOME/extensions/ApprovedRevs \ && git checkout -q a8cb4bd840465a7db1e10654a0969cfc961d8428 \ # Arrays - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Arrays $MW_HOME/extensions/Arrays \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-Arrays $MW_HOME/extensions/Arrays \ && cd $MW_HOME/extensions/Arrays \ && git checkout -q 338f661bf0ab377f70e029079f2c5c5b370219df \ # BetaFeatures - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/BetaFeatures $MW_HOME/extensions/BetaFeatures \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-BetaFeatures $MW_HOME/extensions/BetaFeatures \ && cd $MW_HOME/extensions/BetaFeatures \ && git checkout -q 09cca44341f9695446c4e9fc9e8fec3fdcb197b0 \ # BreadCrumbs2 - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/BreadCrumbs2 $MW_HOME/extensions/BreadCrumbs2 \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-BreadCrumbs2 $MW_HOME/extensions/BreadCrumbs2 \ && cd $MW_HOME/extensions/BreadCrumbs2 \ && git checkout -q d53357a6839e94800a617de4fc451b6c64d0a1c8 \ # Cargo (v. 3.4.1) - && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/Cargo $MW_HOME/extensions/Cargo \ + && git clone --single-branch -b master https://github.com/wikimedia/mediawiki-extensions-Cargo $MW_HOME/extensions/Cargo \ && cd $MW_HOME/extensions/Cargo \ && git checkout -q 04bfe84ef4dc806eab0ec52b361a78542d799474 \ # CharInsert - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/CharInsert $MW_HOME/extensions/CharInsert \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-CharInsert $MW_HOME/extensions/CharInsert \ && cd $MW_HOME/extensions/CharInsert \ && git checkout -q 54c0f0ca9119a3ce791fb5d53edd4ec32035a5c5 \ # CheckUser - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/CheckUser $MW_HOME/extensions/CheckUser \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-CheckUser $MW_HOME/extensions/CheckUser \ && cd $MW_HOME/extensions/CheckUser \ && git checkout -q 9e2b6d3e928855247700146273d8131e025de918 \ # CirrusSearch - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/CirrusSearch $MW_HOME/extensions/CirrusSearch \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-CirrusSearch $MW_HOME/extensions/CirrusSearch \ && cd $MW_HOME/extensions/CirrusSearch \ && git checkout -q 8296300873aaffe815800cf05c84fa04c8cbd2c0 \ # CodeMirror - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/CodeMirror $MW_HOME/extensions/CodeMirror \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-CodeMirror $MW_HOME/extensions/CodeMirror \ && cd $MW_HOME/extensions/CodeMirror \ && git checkout -q 27efed79972ca181a194d17f4a94f4192fd5a493 \ # Collection - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Collection $MW_HOME/extensions/Collection \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-Collection $MW_HOME/extensions/Collection \ && cd $MW_HOME/extensions/Collection \ && git checkout -q e00e70c6fcec963c8876e410e52c83c75ed60827 \ # CommentStreams - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/CommentStreams $MW_HOME/extensions/CommentStreams \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-CommentStreams $MW_HOME/extensions/CommentStreams \ && cd $MW_HOME/extensions/CommentStreams \ && git checkout -q 274bb10bc2d39fd137650dbc0dfc607c766d1aaa \ # CommonsMetadata - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/CommonsMetadata $MW_HOME/extensions/CommonsMetadata \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-CommonsMetadata $MW_HOME/extensions/CommonsMetadata \ && cd $MW_HOME/extensions/CommonsMetadata \ && git checkout -q 8ee30de3b1cabbe55c484839127493fd5fa5d076 \ # ConfirmAccount - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/ConfirmAccount $MW_HOME/extensions/ConfirmAccount \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-ConfirmAccount $MW_HOME/extensions/ConfirmAccount \ && cd $MW_HOME/extensions/ConfirmAccount \ && git checkout -q c06d5dfb43811a2dee99099476c57af2b6d762c4 \ # ContactPage - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/ContactPage $MW_HOME/extensions/ContactPage \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-ContactPage $MW_HOME/extensions/ContactPage \ && cd $MW_HOME/extensions/ContactPage \ && git checkout -q f509796056ae1fc597b6e3c3c268fac35bf66636 \ # ContributionScores - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/ContributionScores $MW_HOME/extensions/ContributionScores \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-ContributionScores $MW_HOME/extensions/ContributionScores \ && cd $MW_HOME/extensions/ContributionScores \ && git checkout -q e307850555ef313f623dde6e2f1d5d2a43663730 \ # CookieWarning - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/CookieWarning $MW_HOME/extensions/CookieWarning \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-CookieWarning $MW_HOME/extensions/CookieWarning \ && cd $MW_HOME/extensions/CookieWarning \ && git checkout -q bc991e93133bd69fe45e07b3d4554225decc7dae \ # DataTransfer - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/DataTransfer $MW_HOME/extensions/DataTransfer \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-DataTransfer $MW_HOME/extensions/DataTransfer \ && cd $MW_HOME/extensions/DataTransfer \ && git checkout -q 2f9f949f71f0bb7d1bd8b6b97c795b9428bb1c71 \ # DeleteBatch - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/DeleteBatch $MW_HOME/extensions/DeleteBatch \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-DeleteBatch $MW_HOME/extensions/DeleteBatch \ && cd $MW_HOME/extensions/DeleteBatch \ && git checkout -q 82078d60fc59a718f429ddebe5e99de8a8734413 \ # Description2 - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Description2 $MW_HOME/extensions/Description2 \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-Description2 $MW_HOME/extensions/Description2 \ && cd $MW_HOME/extensions/Description2 \ && git checkout -q d2a5322a44f940de873050573e35fba4eb3063f8 \ # Disambiguator - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Disambiguator $MW_HOME/extensions/Disambiguator \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-Disambiguator $MW_HOME/extensions/Disambiguator \ && cd $MW_HOME/extensions/Disambiguator \ && git checkout -q b7e7fad5f9f3dccfb902a3cbfd3bf2b16df91871 \ # DismissableSiteNotice - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/DismissableSiteNotice $MW_HOME/extensions/DismissableSiteNotice \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-DismissableSiteNotice $MW_HOME/extensions/DismissableSiteNotice \ && cd $MW_HOME/extensions/DismissableSiteNotice \ && git checkout -q 88129f80f077ec9e4932148056c8cfc1ed0361c7 \ # DisplayTitle - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/DisplayTitle $MW_HOME/extensions/DisplayTitle \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-DisplayTitle $MW_HOME/extensions/DisplayTitle \ && cd $MW_HOME/extensions/DisplayTitle \ && git checkout -q a14c406cc273c73a12957b55a27c095ad98d1795 \ # Echo - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Echo $MW_HOME/extensions/Echo \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-Echo $MW_HOME/extensions/Echo \ && cd $MW_HOME/extensions/Echo \ && git checkout -q fdbc2cafdc412dc60d4345511defe9ee393efecf \ # Editcount - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Editcount $MW_HOME/extensions/Editcount \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-Editcount $MW_HOME/extensions/Editcount \ && cd $MW_HOME/extensions/Editcount \ && git checkout -q 41544ffceb1356f91575dc6772a48b172751d7cc \ # Elastica - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Elastica $MW_HOME/extensions/Elastica \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-Elastica $MW_HOME/extensions/Elastica \ && cd $MW_HOME/extensions/Elastica \ && git checkout -q e4ead38b71ed4f3df8dc689fe448b749771b4ed4 \ # EmailAuthorization - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/EmailAuthorization $MW_HOME/extensions/EmailAuthorization \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-EmailAuthorization $MW_HOME/extensions/EmailAuthorization \ && cd $MW_HOME/extensions/EmailAuthorization \ && git checkout -q 2016da1b354f741d89b5dc207d4a84e11ffe9bce \ # EmbedVideo @@ -251,35 +251,35 @@ RUN set -x; \ && cd $MW_HOME/extensions/EmbedVideo \ && git checkout -q 954af96d3744d8adc7ff6458a05e579784f2d991 \ # EventLogging - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/EventLogging $MW_HOME/extensions/EventLogging \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-EventLogging $MW_HOME/extensions/EventLogging \ && cd $MW_HOME/extensions/EventLogging \ && git checkout -q 2740dbcd139be279ca2a4db039739b4f796b4178 \ # EventStreamConfig - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/EventStreamConfig $MW_HOME/extensions/EventStreamConfig \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-EventStreamConfig $MW_HOME/extensions/EventStreamConfig \ && cd $MW_HOME/extensions/EventStreamConfig \ && git checkout -q 1aae8cb6c312e49f0126091a59a453cb224657f9 \ # ExternalData (v. 3.2) - && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/ExternalData $MW_HOME/extensions/ExternalData \ + && git clone --single-branch -b master https://github.com/wikimedia/mediawiki-extensions-ExternalData $MW_HOME/extensions/ExternalData \ && cd $MW_HOME/extensions/ExternalData \ && git checkout -q 5d30e60a65ca53a3fb5b39826deb2e6917892e22 \ # FlexDiagrams - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/FlexDiagrams $MW_HOME/extensions/FlexDiagrams \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-FlexDiagrams $MW_HOME/extensions/FlexDiagrams \ && cd $MW_HOME/extensions/FlexDiagrams \ && git checkout -q 550d0de3e2525d42952d7bc9d291b26455fe07ce \ # GlobalNotice - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/GlobalNotice $MW_HOME/extensions/GlobalNotice \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-GlobalNotice $MW_HOME/extensions/GlobalNotice \ && cd $MW_HOME/extensions/GlobalNotice \ && git checkout -q 15a40bff4641f00a5a8dda3d36795b1c659c19a7 \ # GoogleAnalyticsMetrics - && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/GoogleAnalyticsMetrics $MW_HOME/extensions/GoogleAnalyticsMetrics \ + && git clone --single-branch -b master https://github.com/wikimedia/mediawiki-extensions-GoogleAnalyticsMetrics $MW_HOME/extensions/GoogleAnalyticsMetrics \ && cd $MW_HOME/extensions/GoogleAnalyticsMetrics \ && git checkout -q 82a08cc63ec58698f144be7c2fb1a6f861cb57bd \ # GoogleDocCreator - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/GoogleDocCreator $MW_HOME/extensions/GoogleDocCreator \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-GoogleDocCreator $MW_HOME/extensions/GoogleDocCreator \ && cd $MW_HOME/extensions/GoogleDocCreator \ && git checkout -q 9e53ecfa4149688a2352a7898c2a2005632e1b7d \ # Graph - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Graph $MW_HOME/extensions/Graph \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-Graph $MW_HOME/extensions/Graph \ && cd $MW_HOME/extensions/Graph \ && git checkout -q 9c229eafdf406c95a4a666a6b7f2a9d0d3d682e4 \ # HeaderFooter @@ -287,131 +287,131 @@ RUN set -x; \ && cd $MW_HOME/extensions/HeaderFooter \ && git checkout -q eee7d2c1a3373c7d6b326fd460e5d4859dd22c40 \ # HeaderTabs (v2.2) - && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/HeaderTabs $MW_HOME/extensions/HeaderTabs \ + && git clone --single-branch -b master https://github.com/wikimedia/mediawiki-extensions-HeaderTabs $MW_HOME/extensions/HeaderTabs \ && cd $MW_HOME/extensions/HeaderTabs \ && git checkout -q 42aaabf1deeb0a228fc99e578ff7ec925e560dd7 \ # HTMLTags - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/HTMLTags $MW_HOME/extensions/HTMLTags \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-HTMLTags $MW_HOME/extensions/HTMLTags \ && cd $MW_HOME/extensions/HTMLTags \ && git checkout -q b8cb3131c5e76f5c037c8474fe14e51f2e877f03 \ # LabeledSectionTransclusion - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/LabeledSectionTransclusion $MW_HOME/extensions/LabeledSectionTransclusion \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-LabeledSectionTransclusion $MW_HOME/extensions/LabeledSectionTransclusion \ && cd $MW_HOME/extensions/LabeledSectionTransclusion \ && git checkout -q 187abfeaafbad35eed4254f7a7ee0638980e932a \ # LDAPAuthentication2 - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/LDAPAuthentication2 $MW_HOME/extensions/LDAPAuthentication2 \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-LDAPAuthentication2 $MW_HOME/extensions/LDAPAuthentication2 \ && cd $MW_HOME/extensions/LDAPAuthentication2 \ && git checkout -q 6bc584893d3157d5180e0e3ed93c3dbbc5b93056 \ # LDAPAuthorization - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/LDAPAuthorization $MW_HOME/extensions/LDAPAuthorization \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-LDAPAuthorization $MW_HOME/extensions/LDAPAuthorization \ && cd $MW_HOME/extensions/LDAPAuthorization \ && git checkout -q e6815d29c22f4b4eb85f868372a729ad49d7d3c8 \ # LDAPProvider - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/LDAPProvider $MW_HOME/extensions/LDAPProvider \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-LDAPProvider $MW_HOME/extensions/LDAPProvider \ && cd $MW_HOME/extensions/LDAPProvider \ && git checkout -q 80f8cc8156b0cd250d0dfacd9378ed0db7c2091d \ # Lingo - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Lingo $MW_HOME/extensions/Lingo \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-Lingo $MW_HOME/extensions/Lingo \ && cd $MW_HOME/extensions/Lingo \ && git checkout -q a291fa25822097a4a2aefff242a876edadb535a4 \ # LinkSuggest - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/LinkSuggest $MW_HOME/extensions/LinkSuggest \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-LinkSuggest $MW_HOME/extensions/LinkSuggest \ && cd $MW_HOME/extensions/LinkSuggest \ && git checkout -q 6005d191e35d1d6bed5a4e7bd1bedc5fa0030bf1 \ # LinkTarget - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/LinkTarget $MW_HOME/extensions/LinkTarget \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-LinkTarget $MW_HOME/extensions/LinkTarget \ && cd $MW_HOME/extensions/LinkTarget \ && git checkout -q e5d592dcc72a00e06604ee3f65dfb8f99977c156 \ # Linter - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Linter $MW_HOME/extensions/Linter \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-Linter $MW_HOME/extensions/Linter \ && cd $MW_HOME/extensions/Linter \ && git checkout -q 8bc1727955da7468f096aa5c5b5790923db43d20 \ # LockAuthor - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/LockAuthor $MW_HOME/extensions/LockAuthor \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-LockAuthor $MW_HOME/extensions/LockAuthor \ && cd $MW_HOME/extensions/LockAuthor \ && git checkout -q 4ebc4f221a0987b64740014a9380e9c3522f271d \ # Lockdown - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Lockdown $MW_HOME/extensions/Lockdown \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-Lockdown $MW_HOME/extensions/Lockdown \ && cd $MW_HOME/extensions/Lockdown \ && git checkout -q ffcb6e8892ad35bb731fad1dc24712a245ab86d0 \ # LookupUser - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/LookupUser $MW_HOME/extensions/LookupUser \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-LookupUser $MW_HOME/extensions/LookupUser \ && cd $MW_HOME/extensions/LookupUser \ && git checkout -q 5fa17d449b6bedb3e8cee5b239af6cadae31da70 \ # Loops - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Loops $MW_HOME/extensions/Loops \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-Loops $MW_HOME/extensions/Loops \ && cd $MW_HOME/extensions/Loops \ && git checkout -q 0eb05a81b9b53f5381eefb4f8b6959b6dcdec1d8 \ # MagicNoCache - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/MagicNoCache $MW_HOME/extensions/MagicNoCache \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-MagicNoCache $MW_HOME/extensions/MagicNoCache \ && cd $MW_HOME/extensions/MagicNoCache \ && git checkout -q 93534c12dac0e821c46c94b21053d274a6e557de \ # MassMessage - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/MassMessage $MW_HOME/extensions/MassMessage \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-MassMessage $MW_HOME/extensions/MassMessage \ && cd $MW_HOME/extensions/MassMessage \ && git checkout -q d6a86291bb975c3dc7778f370006f1145cc834bd \ # MassMessageEmail - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/MassMessageEmail $MW_HOME/extensions/MassMessageEmail \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-MassMessageEmail $MW_HOME/extensions/MassMessageEmail \ && cd $MW_HOME/extensions/MassMessageEmail \ && git checkout -q edd96f14c6d108d56bcecb18b5bb7b3355437732 \ # MediaUploader - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/MediaUploader $MW_HOME/extensions/MediaUploader \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-MediaUploader $MW_HOME/extensions/MediaUploader \ && cd $MW_HOME/extensions/MediaUploader \ && git checkout -q 1edd91c506c1c0319e7b9a3e71d639130760b1fd \ # MintyDocs (1.0) - && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/MintyDocs $MW_HOME/extensions/MintyDocs \ + && git clone --single-branch -b master https://github.com/wikimedia/mediawiki-extensions-MintyDocs $MW_HOME/extensions/MintyDocs \ && cd $MW_HOME/extensions/MintyDocs \ && git checkout -q 4496e33ce71d2c364b16599619c961a1a330bf14 \ # MobileFrontend - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/MobileFrontend $MW_HOME/extensions/MobileFrontend \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-MobileFrontend $MW_HOME/extensions/MobileFrontend \ && cd $MW_HOME/extensions/MobileFrontend \ && git checkout -q f0bed5588f76b827038fb9af73fb9677e5804077 \ # MsUpload - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/MsUpload $MW_HOME/extensions/MsUpload \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-MsUpload $MW_HOME/extensions/MsUpload \ && cd $MW_HOME/extensions/MsUpload \ && git checkout -q dac2376a2fac6ddf4b2038db9b4bc06092ecaa15 \ # MyVariables - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/MyVariables $MW_HOME/extensions/MyVariables \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-MyVariables $MW_HOME/extensions/MyVariables \ && cd $MW_HOME/extensions/MyVariables \ && git checkout -q 8b45be10c9b0a484824c55d8cc48399290384260 \ # NewUserMessage - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/NewUserMessage $MW_HOME/extensions/NewUserMessage \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-NewUserMessage $MW_HOME/extensions/NewUserMessage \ && cd $MW_HOME/extensions/NewUserMessage \ && git checkout -q 206f32880fa7bf70b191d33ed80b8626bca39efe \ # NumerAlpha - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/NumerAlpha $MW_HOME/extensions/NumerAlpha \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-NumerAlpha $MW_HOME/extensions/NumerAlpha \ && cd $MW_HOME/extensions/NumerAlpha \ && git checkout -q 93c0869735581006a3f510096738e262d49f4107 \ # OpenGraphMeta - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/OpenGraphMeta $MW_HOME/extensions/OpenGraphMeta \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-OpenGraphMeta $MW_HOME/extensions/OpenGraphMeta \ && cd $MW_HOME/extensions/OpenGraphMeta \ && git checkout -q d319702cd4ceda1967c233ef8e021b67b3fc355f \ # OpenIDConnect - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/OpenIDConnect $MW_HOME/extensions/OpenIDConnect \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-OpenIDConnect $MW_HOME/extensions/OpenIDConnect \ && cd $MW_HOME/extensions/OpenIDConnect \ && git checkout -q 0824f3cf3800f63e930abf0f03baf1a7c755a270 \ # PageExchange - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/PageExchange $MW_HOME/extensions/PageExchange \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-PageExchange $MW_HOME/extensions/PageExchange \ && cd $MW_HOME/extensions/PageExchange \ && git checkout -q 28482410564e38d2b97ab7321e99c4281c6e5877 \ # PageForms (v. 5.6) - && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/PageForms $MW_HOME/extensions/PageForms \ + && git clone --single-branch -b master https://github.com/wikimedia/mediawiki-extensions-PageForms $MW_HOME/extensions/PageForms \ && cd $MW_HOME/extensions/PageForms \ && git checkout -q d9b0e47a83d951c585f95c97ea10ea8be95adec9 \ # PluggableAuth - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/PluggableAuth $MW_HOME/extensions/PluggableAuth \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-PluggableAuth $MW_HOME/extensions/PluggableAuth \ && cd $MW_HOME/extensions/PluggableAuth \ && git checkout -q 4be1e402e1862d165a4feb003c492ddc9525057e \ # Popups - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Popups $MW_HOME/extensions/Popups \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-Popups $MW_HOME/extensions/Popups \ && cd $MW_HOME/extensions/Popups \ && git checkout -q ff4d2156e1f7f4c11f7396cb0cd70d387abd8187 \ # RegularTooltips - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/RegularTooltips $MW_HOME/extensions/RegularTooltips \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-RegularTooltips $MW_HOME/extensions/RegularTooltips \ && cd $MW_HOME/extensions/RegularTooltips \ && git checkout -q 1af807bb6d5cfbd1e471e38bf70d6a392fb7eda2 \ # RevisionSlider - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/RevisionSlider $MW_HOME/extensions/RevisionSlider \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-RevisionSlider $MW_HOME/extensions/RevisionSlider \ && cd $MW_HOME/extensions/RevisionSlider \ && git checkout -q 3cae51a322a5ca0f359e83efcb5fac38e73e346e \ # RottenLinks @@ -419,11 +419,11 @@ RUN set -x; \ && cd $MW_HOME/extensions/RottenLinks \ && git checkout -q a96e99d0a61a42d59587a67db0720ce245a7ee46 \ # SandboxLink - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/SandboxLink $MW_HOME/extensions/SandboxLink \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-SandboxLink $MW_HOME/extensions/SandboxLink \ && cd $MW_HOME/extensions/SandboxLink \ && git checkout -q 9ab23288a010c3894c59cd5ba3096d93d57c15c5 \ # SaveSpinner - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/SaveSpinner $MW_HOME/extensions/SaveSpinner \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-SaveSpinner $MW_HOME/extensions/SaveSpinner \ && cd $MW_HOME/extensions/SaveSpinner \ && git checkout -q 1e819e2fff7fad6999bafe71d866c3af50836c42 \ # SemanticDependencyUpdater (v. 2.0.2) @@ -435,7 +435,7 @@ RUN set -x; \ && cd $MW_HOME/extensions/SemanticDrilldown \ && git checkout -q e960979ec5a3b1e662b3742cee7e7ef4056f9a46 \ # SimpleChanges - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/SimpleChanges $MW_HOME/extensions/SimpleChanges \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-SimpleChanges $MW_HOME/extensions/SimpleChanges \ && cd $MW_HOME/extensions/SimpleChanges \ && git checkout -q 5352de89dfaf043f646a44582b26f07822f02be7 \ # SimpleMathJax @@ -443,103 +443,103 @@ RUN set -x; \ && cd $MW_HOME/extensions/SimpleMathJax \ && git checkout -q 3757e9b1cf235b2e2c62e7d208d52206e185b28e \ # SkinPerPage - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/SkinPerPage $MW_HOME/extensions/SkinPerPage \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-SkinPerPage $MW_HOME/extensions/SkinPerPage \ && cd $MW_HOME/extensions/SkinPerPage \ && git checkout -q 2793602b37c33aa4c769834feac0b88f385ccef9 \ # SmiteSpam - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/SmiteSpam $MW_HOME/extensions/SmiteSpam \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-SmiteSpam $MW_HOME/extensions/SmiteSpam \ && cd $MW_HOME/extensions/SmiteSpam \ && git checkout -q 268f212b7e366711d8e7b54c7faf5b750fa014ad \ # SocialProfile - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/SocialProfile $MW_HOME/extensions/SocialProfile \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-SocialProfile $MW_HOME/extensions/SocialProfile \ && cd $MW_HOME/extensions/SocialProfile \ && git checkout -q 74fcf9bead948ec0419eea10800c9331bcc1273e \ # TemplateStyles - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/TemplateStyles $MW_HOME/extensions/TemplateStyles \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-TemplateStyles $MW_HOME/extensions/TemplateStyles \ && cd $MW_HOME/extensions/TemplateStyles \ && git checkout -q 2a93b56e370ab8b8e020ed29c507104b56f1d11a \ # TemplateWizard - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/TemplateWizard $MW_HOME/extensions/TemplateWizard \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-TemplateWizard $MW_HOME/extensions/TemplateWizard \ && cd $MW_HOME/extensions/TemplateWizard \ && git checkout -q d486e3475f84118fd9b5c77d60254daa2f56f654 \ # Thanks - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Thanks $MW_HOME/extensions/Thanks \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-Thanks $MW_HOME/extensions/Thanks \ && cd $MW_HOME/extensions/Thanks \ && git checkout -q 03b6a52f263604c819e69b78c157f6ef5adb053e \ # TimedMediaHandler - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/TimedMediaHandler $MW_HOME/extensions/TimedMediaHandler \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-TimedMediaHandler $MW_HOME/extensions/TimedMediaHandler \ && cd $MW_HOME/extensions/TimedMediaHandler \ && git checkout -q 2e64302c68e58693650e91b7869fa5aecf1aaf23 \ # TinyMCE - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/TinyMCE $MW_HOME/extensions/TinyMCE \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-TinyMCE $MW_HOME/extensions/TinyMCE \ && cd $MW_HOME/extensions/TinyMCE \ && git checkout -q 06436ec3a53c6cd53c458e4e8ab3ec8d1a23029b \ # TitleIcon - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/TitleIcon $MW_HOME/extensions/TitleIcon \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-TitleIcon $MW_HOME/extensions/TitleIcon \ && cd $MW_HOME/extensions/TitleIcon \ && git checkout -q 7c6c83f4859642542393612ad961a258378e0cac \ # UniversalLanguageSelector - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/UniversalLanguageSelector $MW_HOME/extensions/UniversalLanguageSelector \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-UniversalLanguageSelector $MW_HOME/extensions/UniversalLanguageSelector \ && cd $MW_HOME/extensions/UniversalLanguageSelector \ && git checkout -q 8216e434c38ddeba74e5ad758bfbbcc83861fa60 \ # UploadWizard - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/UploadWizard $MW_HOME/extensions/UploadWizard \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-UploadWizard $MW_HOME/extensions/UploadWizard \ && cd $MW_HOME/extensions/UploadWizard \ && git checkout -q 847413694b519c76da7196023651c8d584137d2f \ # UrlGetParameters - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/UrlGetParameters $MW_HOME/extensions/UrlGetParameters \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-UrlGetParameters $MW_HOME/extensions/UrlGetParameters \ && cd $MW_HOME/extensions/UrlGetParameters \ && git checkout -q d36f92810c762b301035ff1b4f42792ed9a1018b \ # UserFunctions - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/UserFunctions $MW_HOME/extensions/UserFunctions \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-UserFunctions $MW_HOME/extensions/UserFunctions \ && cd $MW_HOME/extensions/UserFunctions \ && git checkout -q b532b1047080c3738327ee2f3b541e563e06ca19 \ # UserMerge - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/UserMerge $MW_HOME/extensions/UserMerge \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-UserMerge $MW_HOME/extensions/UserMerge \ && cd $MW_HOME/extensions/UserMerge \ && git checkout -q 183bb7a8f78cbe365bec0fbd4b3ecdd4fae1a359 \ # UserPageViewTracker (v. 0.7) - && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/UserPageViewTracker $MW_HOME/extensions/UserPageViewTracker \ + && git clone --single-branch -b master https://github.com/wikimedia/mediawiki-extensions-UserPageViewTracker $MW_HOME/extensions/UserPageViewTracker \ && cd $MW_HOME/extensions/UserPageViewTracker \ && git checkout -q f4b7c20c372165541164d449c12df1e74e98ed0b \ # Variables - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Variables $MW_HOME/extensions/Variables \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-Variables $MW_HOME/extensions/Variables \ && cd $MW_HOME/extensions/Variables \ && git checkout -q b4a9063f16a928567e3b6788cda9246c2e94797f \ # VEForAll (v. 0.4.1) - && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/VEForAll $MW_HOME/extensions/VEForAll \ + && git clone --single-branch -b master https://github.com/wikimedia/mediawiki-extensions-VEForAll $MW_HOME/extensions/VEForAll \ && cd $MW_HOME/extensions/VEForAll \ && git checkout -q 2f1f08eca7fbf61198e5f4ccf2d627a6c9ef7b64 \ # VoteNY - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/VoteNY $MW_HOME/extensions/VoteNY \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-VoteNY $MW_HOME/extensions/VoteNY \ && cd $MW_HOME/extensions/VoteNY \ && git checkout -q 11c103f4b9167a8d8d5e850d8a781c6f49b249c1 \ # WatchAnalytics (v. 3.2.0) - && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/WatchAnalytics $MW_HOME/extensions/WatchAnalytics \ + && git clone --single-branch -b master https://github.com/wikimedia/mediawiki-extensions-WatchAnalytics $MW_HOME/extensions/WatchAnalytics \ && cd $MW_HOME/extensions/WatchAnalytics \ && git checkout -q f6e4d07a93baf502358ce0af01c0ac7e59cc6f4b \ # WhoIsWatching - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/WhoIsWatching $MW_HOME/extensions/WhoIsWatching \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-WhoIsWatching $MW_HOME/extensions/WhoIsWatching \ && cd $MW_HOME/extensions/WhoIsWatching \ && git checkout -q 836a31018e26ab7c993088c4cca31a89efec2ee5 \ # WhosOnline - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/WhosOnline $MW_HOME/extensions/WhosOnline \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-WhosOnline $MW_HOME/extensions/WhosOnline \ && cd $MW_HOME/extensions/WhosOnline \ && git checkout -q bb1765d2eb5c88ca10dc8a0be19f35fcffdccdae \ # Widgets - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Widgets $MW_HOME/extensions/Widgets \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-Widgets $MW_HOME/extensions/Widgets \ && cd $MW_HOME/extensions/Widgets \ && git checkout -q 197d429f971b2aebbce29b7a91a194e1f8181e64 \ # WikiForum - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/WikiForum $MW_HOME/extensions/WikiForum \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-WikiForum $MW_HOME/extensions/WikiForum \ && cd $MW_HOME/extensions/WikiForum \ && git checkout -q a2685b60af86890f199a5f3b6581918369e6a571 \ # WikiSEO - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/WikiSEO $MW_HOME/extensions/WikiSEO \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-WikiSEO $MW_HOME/extensions/WikiSEO \ && cd $MW_HOME/extensions/WikiSEO \ && git checkout -q 610cffa3345333b53d4dda7b55b2012fbfcee9de \ # WSOAuth - && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/WSOAuth $MW_HOME/extensions/WSOAuth \ + && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-WSOAuth $MW_HOME/extensions/WSOAuth \ && cd $MW_HOME/extensions/WSOAuth \ && git checkout -q 3c54c4899dd63989bc3214273bf1c5807c7ac5db From 31216dda3dc54a8f5ceb757a9d8d5e05968c0972 Mon Sep 17 00:00:00 2001 From: Yaron Koren Date: Fri, 10 Mar 2023 08:13:59 -0500 Subject: [PATCH 48/67] Update Dockerfile --- Dockerfile | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/Dockerfile b/Dockerfile index 038924a3..0b5a78fa 100644 --- a/Dockerfile +++ b/Dockerfile @@ -89,7 +89,8 @@ RUN set -x; \ && git submodule update --init --recursive # Skins -# The MonoBook, Timeless and Vector skins are bundled into MediaWiki and do not need to be separately installed. +# The Minerva Neue, MonoBook, Timeless, Vector and Vector 2022 skins are bundled into MediaWiki and do not need to be +# separately installed. # The Chameleon skin is downloaded via Composer and also does not need to be installed. RUN set -x; \ cd $MW_HOME/skins \ @@ -97,10 +98,6 @@ RUN set -x; \ && git clone -b $MW_VERSION --single-branch https://gerrit.wikimedia.org/r/mediawiki/skins/CologneBlue $MW_HOME/skins/CologneBlue \ && cd $MW_HOME/skins/CologneBlue \ && git checkout -q 4d588eb78d7e64e574f631c5897579537305437d \ - # MinervaNeue - #&& git clone -b $MW_VERSION --single-branch https://gerrit.wikimedia.org/r/mediawiki/skins/MinervaNeue $MW_HOME/skins/MinervaNeue \ - #&& cd $MW_HOME/skins/MinervaNeue \ - #&& git checkout -q e4741ff2c4375c2befee0d9f350aff6eb6e1a4da \ # Modern && git clone -b $MW_VERSION --single-branch https://gerrit.wikimedia.org/r/mediawiki/skins/Modern $MW_HOME/skins/Modern \ && cd $MW_HOME/skins/Modern \ From ca83c41a964eaee0fe15451f655a954864a39882 Mon Sep 17 00:00:00 2001 From: Yaron Koren Date: Fri, 10 Mar 2023 08:15:57 -0500 Subject: [PATCH 49/67] Update RELEASE_NOTES.md --- RELEASE_NOTES.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/RELEASE_NOTES.md b/RELEASE_NOTES.md index 4fc48d29..d868c3a8 100644 --- a/RELEASE_NOTES.md +++ b/RELEASE_NOTES.md @@ -8,4 +8,4 @@ Canasta version history: - 1.2.0 - October 2, 2022 - update MediaWiki version to 1.35.8; remove cfLoadExtension() and cfLoadSkin() functionality in favor of symlink-based approach; add displayWikiInfo.php script; make use of gateway.docker.internal to detect host address - 1.2.1 - November 25, 2022 - add AArch64 support; update SimpleBatchUpload extension - 1.2.2 - December 22, 2022 - Fix installation of EmailAuthorization extension; fix web installer to also install Boostrap extension if Chameleon skin gets installed; add MW_MAP_DOMAIN_TO_DOCKER_GATEWAY as an environment variable (set to true by default); remove patches made unnecessary by cfLoad... removal -- 1.3.0 - February 17, 2023 - update MediaWiki version to 1.39.0; update all extensions to a compatible version (in most cases, using the REL1_39 Git branch); add the extensions AbuseFilter, DeleteBatch, MediaUploader, Mermaid, SemanticDependencyUpdater, TemplateWizard, Title Icon, UserPageViewTracker, WatchAnalytics, WhosOnline; remove the extensions DiscussionTools, LocalisationUpdate; add the skins MinervaNeue, Vector 2022; add header warning to email-related special pages if $wgSMTP is not set \ No newline at end of file +- 1.3.0 - February 17, 2023 - update MediaWiki version to 1.39.0; update all extensions to a compatible version (in most cases, using the REL1_39 Git branch); add the extensions AbuseFilter, DeleteBatch, MediaUploader, Mermaid, SemanticDependencyUpdater, TemplateWizard, Title Icon, UserPageViewTracker, WatchAnalytics, WhosOnline; remove the extensions DiscussionTools, LocalisationUpdate; add the skin Vector 2022; add header warning to email-related special pages if $wgSMTP is not set From d79447565b82d9160884e80aafaa7b9057debde5 Mon Sep 17 00:00:00 2001 From: Piyush Raj Date: Wed, 15 Mar 2023 17:16:36 +0530 Subject: [PATCH 50/67] added mpm_event and php-fpm support --- Dockerfile | 11 +++++++++-- _sources/configs/mpm_event.conf | 17 +++++++++++++++++ _sources/configs/mpm_prefork.conf | 16 ---------------- _sources/scripts/run-apache.sh | 4 ++++ 4 files changed, 30 insertions(+), 18 deletions(-) create mode 100644 _sources/configs/mpm_event.conf delete mode 100644 _sources/configs/mpm_prefork.conf diff --git a/Dockerfile b/Dockerfile index 038924a3..82389b20 100644 --- a/Dockerfile +++ b/Dockerfile @@ -58,7 +58,9 @@ RUN set x; \ php7.4-apcu \ php7.4-redis \ php7.4-curl \ - php7.4-zip \ + php7.4-zip \ + php7.4-fpm \ + libapache2-mod-fcgid \ && aptitude clean \ && rm -rf /var/lib/apt/lists/* @@ -70,6 +72,11 @@ RUN set -x; \ && rm -rf /var/www/html \ # Enable rewrite module && a2enmod rewrite \ + # enabling mpm_event and php-fpm + && a2dismod mpm_prefork \ + && a2enconf php7.4-fpm \ + && a2enmod mpm_event \ + && a2enmod proxy_fcgi \ # Create directories && mkdir -p $MW_HOME \ && mkdir -p $MW_ORIGIN_FILES \ @@ -647,7 +654,7 @@ COPY _sources/configs/.htaccess $WWW_ROOT/ COPY _sources/images/favicon.ico $WWW_ROOT/ COPY _sources/canasta/LocalSettings.php _sources/canasta/CanastaUtils.php _sources/canasta/CanastaDefaultSettings.php $MW_HOME/ COPY _sources/canasta/getMediawikiSettings.php / -COPY _sources/configs/mpm_prefork.conf /etc/apache2/mods-available/mpm_prefork.conf +COPY _sources/configs/mpm_event.conf /etc/apache2/mods-available/mpm_event.conf RUN set -x; \ chmod -v +x /*.sh \ diff --git a/_sources/configs/mpm_event.conf b/_sources/configs/mpm_event.conf new file mode 100644 index 00000000..1de09c97 --- /dev/null +++ b/_sources/configs/mpm_event.conf @@ -0,0 +1,17 @@ +# event MPM +# StartServers: number of server processes to start +# ServerLimit: Upper limit on configurable number of processes +# ThreadsPerChild: Number of threads created by each child process +# MaxRequestWorkers: maximum number of server processes allowed to start +# MaxConnectionsPerChild: maximum number of requests a server process serves + + + StartServers 3 + ServerLimit 16 + ThreadsPerChild 25 + MaxRequestWorkers 400 + MaxConnectionsPerChild 0 + + + +# vim: syntax=apache ts=4 sw=4 sts=4 sr noet diff --git a/_sources/configs/mpm_prefork.conf b/_sources/configs/mpm_prefork.conf deleted file mode 100644 index 958f4523..00000000 --- a/_sources/configs/mpm_prefork.conf +++ /dev/null @@ -1,16 +0,0 @@ -# prefork MPM -# StartServers: number of server processes to start -# MinSpareServers: minimum number of server processes which are kept spare -# MaxSpareServers: maximum number of server processes which are kept spare -# MaxRequestWorkers: maximum number of server processes allowed to start -# MaxConnectionsPerChild: maximum number of requests a server process serves - - - StartServers 5 - MinSpareServers 5 - MaxSpareServers 10 - MaxRequestWorkers 150 - MaxConnectionsPerChild 0 - - -# vim: syntax=apache ts=4 sw=4 sts=4 sr noet diff --git a/_sources/scripts/run-apache.sh b/_sources/scripts/run-apache.sh index c440dccb..09ec25b0 100755 --- a/_sources/scripts/run-apache.sh +++ b/_sources/scripts/run-apache.sh @@ -223,6 +223,10 @@ jobrunner & transcoder & sitemapgen & +# Running php-fpm +service php7.4-fpm start + + ############### Run Apache ############### # Make sure we're not confused by old, incompletely-shutdown httpd # context after restarting the container. httpd won't start correctly From 1befb51039c8781a967fbe35b058fbad5ff9794f Mon Sep 17 00:00:00 2001 From: Piyush Raj Date: Fri, 17 Mar 2023 18:48:30 +0530 Subject: [PATCH 51/67] fixed startup of php-fpm --- _sources/scripts/run-apache.sh | 2 +- _sources/scripts/run-php-fpm.sh | 8 ++++++++ 2 files changed, 9 insertions(+), 1 deletion(-) create mode 100755 _sources/scripts/run-php-fpm.sh diff --git a/_sources/scripts/run-apache.sh b/_sources/scripts/run-apache.sh index 09ec25b0..3b00b7de 100755 --- a/_sources/scripts/run-apache.sh +++ b/_sources/scripts/run-apache.sh @@ -224,7 +224,7 @@ transcoder & sitemapgen & # Running php-fpm -service php7.4-fpm start +/run-php-fpm.sh & ############### Run Apache ############### diff --git a/_sources/scripts/run-php-fpm.sh b/_sources/scripts/run-php-fpm.sh new file mode 100755 index 00000000..9dc5f3f3 --- /dev/null +++ b/_sources/scripts/run-php-fpm.sh @@ -0,0 +1,8 @@ +#!/bin/bash + +set -x + +echo "starting php-fpm" +# Running php-fpm +mkdir -p /run/php +exec /usr/sbin/php-fpm7.4 \ No newline at end of file From 8d83a10bc6f835de20a3940ac7b34f43ddc3949f Mon Sep 17 00:00:00 2001 From: Piyush Raj Date: Tue, 21 Mar 2023 23:19:35 +0530 Subject: [PATCH 52/67] fixed php-fpm config --- Dockerfile | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 82389b20..b4963526 100644 --- a/Dockerfile +++ b/Dockerfile @@ -668,7 +668,9 @@ RUN set -x; \ && sed -i 's/MW_CONFIG_FILE/CANASTA_CONFIG_FILE/g' "$MW_HOME/includes/CanastaNoLocalSettings.php" \ # Modify config && sed -i '//,/<\/Directory>/ s/AllowOverride None/AllowOverride All/' /etc/apache2/apache2.conf \ - && a2enmod expires + && a2enmod expires \ + # Enable environment variables for FPM workers + && sed -i '/clear_env/s/^;//' /etc/php/7.4/fpm/pool.d/www.conf COPY _sources/images/Powered-by-Canasta.png /var/www/mediawiki/w/resources/assets/ From 8a44a573cde7b8f02e3feac0d5a40397d2d63606 Mon Sep 17 00:00:00 2001 From: Pavel Astakhov Date: Mon, 27 Mar 2023 19:42:35 +0600 Subject: [PATCH 53/67] Update VEForAll up to version 0.5 The CommentStreams extension does not work with 0.4.1 version --- Dockerfile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index 0b5a78fa..d192a877 100644 --- a/Dockerfile +++ b/Dockerfile @@ -503,10 +503,10 @@ RUN set -x; \ && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/Variables $MW_HOME/extensions/Variables \ && cd $MW_HOME/extensions/Variables \ && git checkout -q b4a9063f16a928567e3b6788cda9246c2e94797f \ - # VEForAll (v. 0.4.1) + # VEForAll (v. 0.5) && git clone --single-branch -b master https://gerrit.wikimedia.org/r/mediawiki/extensions/VEForAll $MW_HOME/extensions/VEForAll \ && cd $MW_HOME/extensions/VEForAll \ - && git checkout -q 2f1f08eca7fbf61198e5f4ccf2d627a6c9ef7b64 \ + && git checkout -q cffa12abb85200e90b1cbc636325b1ec1a89a6af \ # VoteNY && git clone --single-branch -b $MW_VERSION https://gerrit.wikimedia.org/r/mediawiki/extensions/VoteNY $MW_HOME/extensions/VoteNY \ && cd $MW_HOME/extensions/VoteNY \ From 26ac5fde4922bcf04781f824dbda328e23270301 Mon Sep 17 00:00:00 2001 From: freephile Date: Wed, 29 Mar 2023 00:18:42 -0400 Subject: [PATCH 54/67] Add missing quotes for strings --- _sources/canasta/CanastaDefaultSettings.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/_sources/canasta/CanastaDefaultSettings.php b/_sources/canasta/CanastaDefaultSettings.php index b4c69f56..193542b2 100644 --- a/_sources/canasta/CanastaDefaultSettings.php +++ b/_sources/canasta/CanastaDefaultSettings.php @@ -66,9 +66,9 @@ # see https://www.mediawiki.org/wiki/Manual:$wgCdnServersNoPurge $wgUseCdn = true; $wgCdnServersNoPurge = []; -$wgCdnServersNoPurge[] = 10.0.0.0/8; // 10.0.0.0 – 10.255.255.255 -$wgCdnServersNoPurge[] = 172.16.0.0/12; // 172.16.0.0 – 172.31.255.255 -$wgCdnServersNoPurge[] = 192.168.0.0/16; // 192.168.0.0 – 192.168.255.255 +$wgCdnServersNoPurge[] = '10.0.0.0/8'; // 10.0.0.0 – 10.255.255.255 +$wgCdnServersNoPurge[] = '172.16.0.0/12'; // 172.16.0.0 – 172.31.255.255 +$wgCdnServersNoPurge[] = '192.168.0.0/16'; // 192.168.0.0 – 192.168.255.255 # Include user defined LocalSettings.php file require_once "$canastaLocalSettingsFilePath"; From 0bf7b154bda574ecc8ed172f78d4a362d7ebd03b Mon Sep 17 00:00:00 2001 From: Yaron Koren Date: Thu, 30 Mar 2023 12:23:56 -0400 Subject: [PATCH 55/67] Update CanastaUtils.php (#227) --- _sources/canasta/CanastaUtils.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/_sources/canasta/CanastaUtils.php b/_sources/canasta/CanastaUtils.php index 50fb9c9b..b5f3cc72 100644 --- a/_sources/canasta/CanastaUtils.php +++ b/_sources/canasta/CanastaUtils.php @@ -39,6 +39,9 @@ function cfLoadSkin( $skinName ) { $specialPage = MediaWiki\MediaWikiServices::getInstance() ->getSpecialPageFactory() ->getPage( $title->getText() ); + if ( $specialPage == null ) { + return; + } $canonicalName = $specialPage->getName(); // Only display this warning for pages that could result in an email getting sent. $specialPagesWithEmail = [ 'Preferences', 'CreateAccount' ]; From 8e0d8325693e5cd985c3f85805ac41ed546a2830 Mon Sep 17 00:00:00 2001 From: Pavel Astakhov Date: Fri, 7 Apr 2023 01:00:14 +0600 Subject: [PATCH 56/67] Fix the URL to PR in the github-actions message --- .github/workflows/docker-image.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/docker-image.yml b/.github/workflows/docker-image.yml index 70d3af63..2ba1984e 100644 --- a/.github/workflows/docker-image.yml +++ b/.github/workflows/docker-image.yml @@ -163,6 +163,6 @@ jobs: repository: ${{ github.repository }} number: ${{ github.event.number }} id: comment - message: ":whale: The image based on [${{ steps.generate.outputs.SHA_SHORT }}](https://github.com/WikiTeq/docker-wikiteq-canasta/pull/${{ steps.generate.outputs.REGISTRY_TAGS_PR_NUMBER }}/commits/${{ github.event.pull_request.head.sha }}) commit has been built with `${{ steps.generate.outputs.REGISTRY_TAGS_VERSION }}` tag as [${{ steps.generate.outputs.REGISTRY_TAGS }}](https://github.com/${{ github.repository }}/pkgs/container/${{ env.IMAGE_NAME }}/${{ steps.docker_build.outputs.imageid }}?tag=${{ steps.generate.outputs.REGISTRY_TAGS_VERSION }})" + message: ":whale: The image based on [${{ steps.generate.outputs.SHA_SHORT }}](https://github.com/CanastaWiki/Canasta/pull/${{ steps.generate.outputs.REGISTRY_TAGS_PR_NUMBER }}/commits/${{ github.event.pull_request.head.sha }}) commit has been built with `${{ steps.generate.outputs.REGISTRY_TAGS_VERSION }}` tag as [${{ steps.generate.outputs.REGISTRY_TAGS }}](https://github.com/${{ github.repository }}/pkgs/container/${{ env.IMAGE_NAME }}/${{ steps.docker_build.outputs.imageid }}?tag=${{ steps.generate.outputs.REGISTRY_TAGS_VERSION }})" recreate: true fail: false From e5f8b5611c1fe8d3bab4beff895d64a43641c279 Mon Sep 17 00:00:00 2001 From: Pavel Astakhov Date: Fri, 7 Apr 2023 01:25:44 +0600 Subject: [PATCH 57/67] remove branches: 1.2.x --- .github/workflows/docker-image.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/docker-image.yml b/.github/workflows/docker-image.yml index 6aa8e33d..37ee5a97 100644 --- a/.github/workflows/docker-image.yml +++ b/.github/workflows/docker-image.yml @@ -9,7 +9,6 @@ on: # Only activate for `master` branch branches: - master - - 1.2.x # Plus for all tags tags: - '*' From 505c98cb2208e67bf0c5c1afbec0405e6c56c360 Mon Sep 17 00:00:00 2001 From: Pavel Astakhov Date: Fri, 7 Apr 2023 01:31:59 +0600 Subject: [PATCH 58/67] Remove COPY _sources/patches/skin-refreshed.patch /tmp/skin-refreshed.patch --- Dockerfile | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index 208f4844..b9d35722 100644 --- a/Dockerfile +++ b/Dockerfile @@ -818,8 +818,7 @@ RUN set -x; \ cd $MW_HOME/extensions/Flow \ && git apply /tmp/flow-conversion-utils.patch -# TODO send to upstream, see https://wikiteq.atlassian.net/browse/MW-64 and https://wikiteq.atlassian.net/browse/MW-81 -COPY _sources/patches/skin-refreshed.patch /tmp/skin-refreshed.patch +# TODO send to upstream, see https://wikiteq.atlassian.net/browse/MW-81 COPY _sources/patches/skin-refreshed-737080.diff /tmp/skin-refreshed-737080.diff RUN set -x; \ cd $MW_HOME/skins/Refreshed \ From 5110f32cb528cbd49a86a5e92ccdc5bf76b2b08d Mon Sep 17 00:00:00 2001 From: Pavel Astakhov Date: Fri, 7 Apr 2023 01:51:17 +0600 Subject: [PATCH 59/67] Restore _sources/patches/skin-refreshed.patch (it is not fixed yet) --- Dockerfile | 3 ++- _sources/patches/skin-refreshed.patch | 11 +++++++++++ 2 files changed, 13 insertions(+), 1 deletion(-) create mode 100644 _sources/patches/skin-refreshed.patch diff --git a/Dockerfile b/Dockerfile index b9d35722..208f4844 100644 --- a/Dockerfile +++ b/Dockerfile @@ -818,7 +818,8 @@ RUN set -x; \ cd $MW_HOME/extensions/Flow \ && git apply /tmp/flow-conversion-utils.patch -# TODO send to upstream, see https://wikiteq.atlassian.net/browse/MW-81 +# TODO send to upstream, see https://wikiteq.atlassian.net/browse/MW-64 and https://wikiteq.atlassian.net/browse/MW-81 +COPY _sources/patches/skin-refreshed.patch /tmp/skin-refreshed.patch COPY _sources/patches/skin-refreshed-737080.diff /tmp/skin-refreshed-737080.diff RUN set -x; \ cd $MW_HOME/skins/Refreshed \ diff --git a/_sources/patches/skin-refreshed.patch b/_sources/patches/skin-refreshed.patch new file mode 100644 index 00000000..6cc131c7 --- /dev/null +++ b/_sources/patches/skin-refreshed.patch @@ -0,0 +1,11 @@ +--- includes/RefreshedTemplate.20210207.php 2020-12-23 04:43:50.000000000 -0700 ++++ includes/RefreshedTemplate.php 2021-02-07 15:13:47.046242557 -0700 +@@ -384,7 +384,7 @@ + $html = $doc->loadHTML( $text, LIBXML_HTML_NOIMPLIED | LIBXML_HTML_NODEFDTD ); + if ( $html === false ) { + foreach ( libxml_get_errors() as $error ) { +- echo "\n", $error->message; ++ echo "'; + } + return false; + } From fa0240593546eaa97f9e6978b669ac5b106ce45a Mon Sep 17 00:00:00 2001 From: Jeffrey Wang Date: Thu, 6 Apr 2023 23:25:10 -0500 Subject: [PATCH 60/67] Update VERSION --- VERSION | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/VERSION b/VERSION index 589268e6..126f4f30 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -1.3.0 \ No newline at end of file +1.3.1-pre From fd5f3327c2bd17db3841c056c4b80320bd099d36 Mon Sep 17 00:00:00 2001 From: Pavel Astakhov Date: Fri, 7 Apr 2023 18:00:55 +0600 Subject: [PATCH 61/67] Fix for case when web container can't start after incompletely-shutdown The patch to the pid file was not changed when the base image was changed from centos to debian. --- _sources/scripts/run-apache.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/_sources/scripts/run-apache.sh b/_sources/scripts/run-apache.sh index 953d0276..d686afd4 100755 --- a/_sources/scripts/run-apache.sh +++ b/_sources/scripts/run-apache.sh @@ -199,6 +199,6 @@ inotifywait & # Make sure we're not confused by old, incompletely-shutdown httpd # context after restarting the container. httpd won't start correctly # if it thinks it is already running. -rm -rf /run/httpd/* /tmp/httpd* +rm -rf /run/apache2/* /tmp/apache2* exec /usr/sbin/apachectl -DFOREGROUND From ec3d92be641e51b6b2b01cb74d4a1b8740df912e Mon Sep 17 00:00:00 2001 From: Pavel Astakhov Date: Fri, 7 Apr 2023 18:51:34 +0600 Subject: [PATCH 62/67] Remove inotify-tools --- Dockerfile | 1 - 1 file changed, 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 00be9f32..49bc75bd 100644 --- a/Dockerfile +++ b/Dockerfile @@ -22,7 +22,6 @@ RUN set x; \ && aptitude -y upgrade \ && aptitude install -y \ git \ - inotify-tools \ apache2 \ software-properties-common \ gpg \ From 9fc92805218797f3aed559a3e3da8df99b824c1f Mon Sep 17 00:00:00 2001 From: Pavel Astakhov Date: Fri, 7 Apr 2023 18:54:46 +0600 Subject: [PATCH 63/67] Fix typo in Dockerfile --- Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 49bc75bd..e672ce5a 100644 --- a/Dockerfile +++ b/Dockerfile @@ -939,7 +939,7 @@ RUN set -x; \ # For Widgets extension && mkdir -p $MW_ORIGIN_FILES/extensions/Widgets \ && mv $MW_HOME/extensions/Widgets/compiled_templates $MW_ORIGIN_FILES/extensions/Widgets/ \ - && ln -s $MW_VOLUME/extensions/Widgets/compiled_templates $MW_HOME/extensions/Widgets/compiled_templates + && ln -s $MW_VOLUME/extensions/Widgets/compiled_templates $MW_HOME/extensions/Widgets/compiled_templates \ # Enable environment variables for FPM workers && sed -i '/clear_env/s/^;//' /etc/php/7.4/fpm/pool.d/www.conf From 3dab9acd2988ce050a5ab62145f60de2625a316b Mon Sep 17 00:00:00 2001 From: Pavel Astakhov Date: Sat, 15 Apr 2023 20:55:00 +0600 Subject: [PATCH 64/67] Remove mention of LocalisationUpdate in Dockerfile The LocalisationUpdate extension no longer bundled in MediaWiki since 1.38 --- Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index b076c5d7..3072f551 100644 --- a/Dockerfile +++ b/Dockerfile @@ -122,7 +122,7 @@ RUN set -x; \ # Extensions # The following extensions are bundled into MediaWiki and do not need to be separately installed (though in some cases # they are modified): AbuseFilter, CategoryTree, Cite, CiteThisPage, CodeEditor, ConfirmEdit, Gadgets, ImageMap, -# InputBox, Interwiki, LocalisationUpdate, Math, MultimediaViewer, Nuke, OATHAuth, PageImages, ParserFunctions, +# InputBox, Interwiki, Math, MultimediaViewer, Nuke, OATHAuth, PageImages, ParserFunctions, # PdfHandler, Poem, Renameuser, Replace Text, Scribunto, SecureLinkFixer, SpamBlacklist, SyntaxHighlight, TemplateData, # TextExtracts, TitleBlacklist, VisualEditor, WikiEditor. # The following extensions are downloaded via Composer and also do not need to be downloaded here: Bootstrap, From d1b11e8c320faaa2c75aff06cfa72dc8fe9b816f Mon Sep 17 00:00:00 2001 From: Pavel Astakhov Date: Wed, 26 Apr 2023 23:48:52 +0600 Subject: [PATCH 65/67] Move php config files from apache2/conf.d to fpm/conf.d --- Dockerfile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Dockerfile b/Dockerfile index 9de41d1a..afd58f53 100644 --- a/Dockerfile +++ b/Dockerfile @@ -922,9 +922,9 @@ COPY _sources/configs/mediawiki.conf /etc/apache2/sites-enabled/ COPY _sources/configs/status.conf /etc/apache2/mods-available/ COPY _sources/configs/scan.conf /etc/clamd.d/scan.conf COPY _sources/configs/php_xdebug.ini _sources/configs/php_memory_limit.ini _sources/configs/php_error_reporting.ini _sources/configs/php_upload_max_filesize.ini /etc/php/7.4/cli/conf.d/ -COPY _sources/configs/php_xdebug.ini _sources/configs/php_memory_limit.ini _sources/configs/php_error_reporting.ini _sources/configs/php_upload_max_filesize.ini /etc/php/7.4/apache2/conf.d/ -COPY _sources/configs/php_max_input_vars.ini _sources/configs/php_max_input_vars.ini /etc/php/7.4/apache2/conf.d/ -COPY _sources/configs/php_timeouts.ini /etc/php/7.4/apache2/conf.d/ +COPY _sources/configs/php_xdebug.ini _sources/configs/php_memory_limit.ini _sources/configs/php_error_reporting.ini _sources/configs/php_upload_max_filesize.ini /etc/php/7.4/fpm/conf.d/ +COPY _sources/configs/php_max_input_vars.ini _sources/configs/php_max_input_vars.ini /etc/php/7.4/fpm/conf.d/ +COPY _sources/configs/php_timeouts.ini /etc/php/7.4/fpm/conf.d/ COPY _sources/scripts/*.sh / COPY _sources/scripts/*.php $MW_HOME/maintenance/ COPY _sources/configs/robots.txt $WWW_ROOT/ From d16138952fb687047d7d4f23a083508d558cc3dd Mon Sep 17 00:00:00 2001 From: Yaron Koren Date: Mon, 1 May 2023 18:16:51 -0400 Subject: [PATCH 66/67] Update versions of six extensions (#232) Admin Links, Approved Revs, Cargo, Flex Diagrams, Page Forms, WatchAnalytics. --- Dockerfile | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/Dockerfile b/Dockerfile index 3072f551..930c9ab6 100644 --- a/Dockerfile +++ b/Dockerfile @@ -131,10 +131,10 @@ RUN set -x; \ # Formats, Semantic Scribunto, SimpleBatchUpload, SubPageList. RUN set -x; \ cd $MW_HOME/extensions \ - # AdminLinks - && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-AdminLinks $MW_HOME/extensions/AdminLinks \ + # AdminLinks (v. 0.6.1) + && git clone --single-branch -b master https://github.com/wikimedia/mediawiki-extensions-AdminLinks $MW_HOME/extensions/AdminLinks \ && cd $MW_HOME/extensions/AdminLinks \ - && git checkout -q ad7805941ee29378484d1ef3595041f7d2c15913 \ + && git checkout -q 3e2671c21fd4b8644552069ee60220035b6e96f5 \ # AdvancedSearch && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-AdvancedSearch $MW_HOME/extensions/AdvancedSearch \ && cd $MW_HOME/extensions/AdvancedSearch \ @@ -147,10 +147,10 @@ RUN set -x; \ && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-AntiSpoof $MW_HOME/extensions/AntiSpoof \ && cd $MW_HOME/extensions/AntiSpoof \ && git checkout -q 01cf89a678d5bab6610d24e07d3534356a5880cb \ - # ApprovedRevs (v. 1.8.1) + # ApprovedRevs (v. 1.8.2) && git clone --single-branch -b master https://github.com/wikimedia/mediawiki-extensions-ApprovedRevs $MW_HOME/extensions/ApprovedRevs \ && cd $MW_HOME/extensions/ApprovedRevs \ - && git checkout -q a8cb4bd840465a7db1e10654a0969cfc961d8428 \ + && git checkout -q 53b67bf7e1e8ac3d20c2fd41ad2ab1c708c045a6 \ # Arrays && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-Arrays $MW_HOME/extensions/Arrays \ && cd $MW_HOME/extensions/Arrays \ @@ -163,10 +163,10 @@ RUN set -x; \ && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-BreadCrumbs2 $MW_HOME/extensions/BreadCrumbs2 \ && cd $MW_HOME/extensions/BreadCrumbs2 \ && git checkout -q d53357a6839e94800a617de4fc451b6c64d0a1c8 \ - # Cargo (v. 3.4.1) + # Cargo (v. 3.4.2) && git clone --single-branch -b master https://github.com/wikimedia/mediawiki-extensions-Cargo $MW_HOME/extensions/Cargo \ && cd $MW_HOME/extensions/Cargo \ - && git checkout -q 04bfe84ef4dc806eab0ec52b361a78542d799474 \ + && git checkout -q 7e8ea881cdb41e79687d059670fc68872a6a892c \ # CharInsert && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-CharInsert $MW_HOME/extensions/CharInsert \ && cd $MW_HOME/extensions/CharInsert \ @@ -267,10 +267,10 @@ RUN set -x; \ && git clone --single-branch -b master https://github.com/wikimedia/mediawiki-extensions-ExternalData $MW_HOME/extensions/ExternalData \ && cd $MW_HOME/extensions/ExternalData \ && git checkout -q 5d30e60a65ca53a3fb5b39826deb2e6917892e22 \ - # FlexDiagrams - && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-FlexDiagrams $MW_HOME/extensions/FlexDiagrams \ + # FlexDiagrams (v. 0.5) + && git clone --single-branch -b master https://github.com/wikimedia/mediawiki-extensions-FlexDiagrams $MW_HOME/extensions/FlexDiagrams \ && cd $MW_HOME/extensions/FlexDiagrams \ - && git checkout -q 550d0de3e2525d42952d7bc9d291b26455fe07ce \ + && git checkout -q eefc9e29aedfc6d8ffaf4f4e50043b390ebd7adc \ # GlobalNotice && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-GlobalNotice $MW_HOME/extensions/GlobalNotice \ && cd $MW_HOME/extensions/GlobalNotice \ @@ -399,10 +399,10 @@ RUN set -x; \ && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-PageExchange $MW_HOME/extensions/PageExchange \ && cd $MW_HOME/extensions/PageExchange \ && git checkout -q 28482410564e38d2b97ab7321e99c4281c6e5877 \ - # PageForms (v. 5.6) + # PageForms (v. 5.6.1) && git clone --single-branch -b master https://github.com/wikimedia/mediawiki-extensions-PageForms $MW_HOME/extensions/PageForms \ && cd $MW_HOME/extensions/PageForms \ - && git checkout -q d9b0e47a83d951c585f95c97ea10ea8be95adec9 \ + && git checkout -q f90d67ecc2c111e82db454c71592c83384ff9704 \ # PluggableAuth && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-PluggableAuth $MW_HOME/extensions/PluggableAuth \ && cd $MW_HOME/extensions/PluggableAuth \ @@ -519,10 +519,10 @@ RUN set -x; \ && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-VoteNY $MW_HOME/extensions/VoteNY \ && cd $MW_HOME/extensions/VoteNY \ && git checkout -q 11c103f4b9167a8d8d5e850d8a781c6f49b249c1 \ - # WatchAnalytics (v. 3.2.0) + # WatchAnalytics (v. 4.1.0) && git clone --single-branch -b master https://github.com/wikimedia/mediawiki-extensions-WatchAnalytics $MW_HOME/extensions/WatchAnalytics \ && cd $MW_HOME/extensions/WatchAnalytics \ - && git checkout -q f6e4d07a93baf502358ce0af01c0ac7e59cc6f4b \ + && git checkout -q 793a03b21992c63bc431e3bf0835351958315fb8 \ # WhoIsWatching && git clone --single-branch -b $MW_VERSION https://github.com/wikimedia/mediawiki-extensions-WhoIsWatching $MW_HOME/extensions/WhoIsWatching \ && cd $MW_HOME/extensions/WhoIsWatching \ From 991d0d25f9fc46b8b00b632b7d7d72010cb2b9db Mon Sep 17 00:00:00 2001 From: Pavel Astakhov Date: Thu, 27 Apr 2023 00:00:18 +0600 Subject: [PATCH 67/67] Fix path for php-fpm config files --- Dockerfile | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/Dockerfile b/Dockerfile index 930c9ab6..dd19ca34 100644 --- a/Dockerfile +++ b/Dockerfile @@ -59,7 +59,7 @@ RUN set x; \ php7.4-apcu \ php7.4-redis \ php7.4-curl \ - php7.4-zip \ + php7.4-zip \ php7.4-fpm \ libapache2-mod-fcgid \ && aptitude clean \ @@ -642,9 +642,9 @@ COPY _sources/configs/msmtprc /etc/ COPY _sources/configs/mediawiki.conf /etc/apache2/sites-enabled/ COPY _sources/configs/status.conf /etc/apache2/mods-available/ COPY _sources/configs/php_error_reporting.ini _sources/configs/php_upload_max_filesize.ini /etc/php/7.4/cli/conf.d/ -COPY _sources/configs/php_error_reporting.ini _sources/configs/php_upload_max_filesize.ini /etc/php/7.4/apache2/conf.d/ -COPY _sources/configs/php_max_input_vars.ini _sources/configs/php_max_input_vars.ini /etc/php/7.4/apache2/conf.d/ -COPY _sources/configs/php_timeouts.ini /etc/php/7.4/apache2/conf.d/ +COPY _sources/configs/php_error_reporting.ini _sources/configs/php_upload_max_filesize.ini /etc/php/7.4/fpm/conf.d/ +COPY _sources/configs/php_max_input_vars.ini _sources/configs/php_max_input_vars.ini /etc/php/7.4/fpm/conf.d/ +COPY _sources/configs/php_timeouts.ini /etc/php/7.4/fpm/conf.d/ COPY _sources/scripts/*.sh / COPY _sources/scripts/*.php $MW_HOME/maintenance/ COPY _sources/configs/robots.txt $WWW_ROOT/ @@ -661,14 +661,14 @@ RUN set -x; \ # Comment out ErrorLog and CustomLog parameters, we use rotatelogs in mediawiki.conf for the log files && sed -i 's/^\(\s*ErrorLog .*\)/# \1/g' /etc/apache2/apache2.conf \ && sed -i 's/^\(\s*CustomLog .*\)/# \1/g' /etc/apache2/apache2.conf \ - # Make web installer work with Canasta - && cp "$MW_HOME/includes/NoLocalSettings.php" "$MW_HOME/includes/CanastaNoLocalSettings.php" \ - && sed -i 's/MW_CONFIG_FILE/CANASTA_CONFIG_FILE/g' "$MW_HOME/includes/CanastaNoLocalSettings.php" \ - # Modify config - && sed -i '//,/<\/Directory>/ s/AllowOverride None/AllowOverride All/' /etc/apache2/apache2.conf \ - && a2enmod expires \ + # Make web installer work with Canasta + && cp "$MW_HOME/includes/NoLocalSettings.php" "$MW_HOME/includes/CanastaNoLocalSettings.php" \ + && sed -i 's/MW_CONFIG_FILE/CANASTA_CONFIG_FILE/g' "$MW_HOME/includes/CanastaNoLocalSettings.php" \ + # Modify config + && sed -i '//,/<\/Directory>/ s/AllowOverride None/AllowOverride All/' /etc/apache2/apache2.conf \ + && a2enmod expires \ # Enable environment variables for FPM workers - && sed -i '/clear_env/s/^;//' /etc/php/7.4/fpm/pool.d/www.conf + && sed -i '/clear_env/s/^;//' /etc/php/7.4/fpm/pool.d/www.conf COPY _sources/images/Powered-by-Canasta.png /var/www/mediawiki/w/resources/assets/
    -- plain() ) . "' /> -+ escaped() . "' /> -