Skip to content

Commit

Permalink
Auto-update Tech namespace pages 2024-09-21 05:49:42.251750
Browse files Browse the repository at this point in the history
  • Loading branch information
Universal-Omega committed Sep 21, 2024
1 parent 60ee447 commit aff6f6c
Show file tree
Hide file tree
Showing 4 changed files with 47 additions and 4 deletions.
4 changes: 2 additions & 2 deletions content/tech-docs/Tech:MediaWiki_appserver.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ A full list of maintenance scripts can be found [here](https://meta.miraheze.org

**Foreachwikiindblist** allows for a maintenance script to be run on all Miraheze wikis.

Usage: ` sudo -u www-data /usr/local/bin/foreachwikiindblist /srv/mediawiki/cache/databases.json /srv/mediawiki/<version>/maintenance/example.php`
Usage: ` sudo -u www-data /usr/local/bin/foreachwikiindblist /srv/mediawiki/cache/databases.php /srv/mediawiki/<version>/maintenance/example.php`

### mwscript

Expand Down Expand Up @@ -77,7 +77,7 @@ To significantly reduce these potential security risks, we use [Firejail](https:

## ManageWiki Cache

ManageWiki uses a caching backend for its settings, extensions, permissions, and namespaces. This caching system provides that each wiki has a JSON file located in `/srv/mediawiki/cache` with this information. In case that there is an issue with the ManageWiki cache for a specific wiki, the following can be used with `shell.php`: `$cw = new Miraheze\CreateWiki\CreateWikiJson( '<dbname>' ); $cw->resetWiki();`
ManageWiki uses a caching backend for its settings, extensions, permissions, and namespaces. This caching system provides that each wiki has a PHP file located in `/srv/mediawiki/cache` with this information. In case that there is an issue with the ManageWiki cache for a specific wiki, the following can be used with `shell.php`: `$cw = new Miraheze\CreateWiki\CreateWikiPhp( '<dbname>' ); $cw->resetWiki();`

## Composer

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ In case of any doubts regarding a command or configuration change, MediaWiki Spe
* Always `!log` maintenance script runs in #miraheze-tech-ops (unless you were running puppet or were using sql.php, and did **not** execute any queries that changed the database (e.g. SELECT/DESCRIBE queries)
* You can optionally use the [mwscript](/tech-docs/techmediawiki_appserver#mwscript) wrapper to automatically log these.
* If you need to run a script on all wikis, use the *foreachwikiindblist* wrapper:
* `sudo -u www-data /usr/local/bin/foreachwikiindblist /srv/mediawiki/cache/databases.json /srv/mediawiki/<version>/maintenance/yourscript.php --put-your-parameters --here`
* `sudo -u www-data /usr/local/bin/foreachwikiindblist /srv/mediawiki/cache/databases.php /srv/mediawiki/<version>/maintenance/yourscript.php --put-your-parameters --here`
* update.php is evil. It should absolutely never be ran in production.
* SQL files should be added to the CreateWiki config setting so that tables are automatically added to all new wikis. See [Tech:Adding a new extension](/tech-docs/techadding_a_new_extension) for enabling extensions or adding tables to existing wikis.

Expand Down
2 changes: 1 addition & 1 deletion content/tech-docs/Tech:Removing_an_extension.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ The steps below must be done in this order:

* Generate a list of all wikis using the extension with `/srv/mediawiki/<VERSION>/extensions/MirahezeMagic/maintenance/generateExtensionDatabaseList.php --wiki=loginwiki --extension=extension --directory=/srv/mediawiki`. This will create a JSON list in `/srv/mediawiki` called `<EXTENSION>.json`
* Run `sudo -u www-data /usr/local/bin/foreachwikiindblist /srv/mediawiki/<EXTENSION>.json /srv/mediawiki/<VERSION>/extensions/ManageWiki/maintenance/toggleExtension.php --disable extension`
* Remove any settings configured using `sudo -u www-data /usr/local/bin/foreachwikiindblist /srv/mediawiki/cache/databases.json /srv/mediawiki/<VERSION>/extensions/ManageWiki/maintenance/populateWikiSettings.php --wgsetting=wgSettingName --sourcelist=false --remove`
* Remove any settings configured using `sudo -u www-data /usr/local/bin/foreachwikiindblist /srv/mediawiki/cache/databases.php /srv/mediawiki/<VERSION>/extensions/ManageWiki/maintenance/populateWikiSettings.php --wgsetting=wgSettingName --sourcelist=false --remove`
* Remove any existing configuration from ManageWikiExtensions.php, LocalSettings.php, and GlobalSettings.php. (Note: If the extension has extra settings in ManageWikiSettings.php, make sure to remove that too)
* Remove the extension from the mediawiki-repos on GitHub after the settings above have been successfully removed.

Expand Down
43 changes: 43 additions & 0 deletions content/tech-docs/Tech:Server_admin_log.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,49 @@
title: Tech:Server admin log
---

## 2024-09-21

* 05:37 MirahezeLSBot: [@mwtask171] finished deploy of {'config': True} to all - SUCCESS in 21s
* 05:36 MirahezeLSBot: [@mwtask171] starting deploy of {'config': True} to all
* 05:34 MirahezeLSBot: [universalomega@mwtask181] sudo -u www-data /usr/local/bin/foreachwikiindblist /srv/mediawiki/cache/databases.php /srv/mediawiki/1.42/maintenance/run.php /srv/mediawiki/1.42/maintenance/initSiteStats.php (END - exit=2)
* 05:34 MirahezeLSBot: [universalomega@mwtask181] sudo -u www-data /usr/local/bin/foreachwikiindblist /srv/mediawiki/cache/databases.php /srv/mediawiki/1.42/maintenance/run.php /srv/mediawiki/1.42/maintenance/initSiteStats.php (START)
* 05:16 Universal Omega: sudo rm /srv/mediawiki/cache/�.json on mw�, and mwtask*
* 05:07 MirahezeLSBot: [universalomega@mwtask181] finished deploy of {'pull': 'config', 'config': True, 'force': True} to all - SUCCESS in 26s
* 05:06 MirahezeLSBot: [universalomega@mwtask181] starting deploy of {'pull': 'config', 'config': True, 'force': True} to all
* 05:02 MirahezeLSBot: [salt-user@mw152] sudo -u www-data php /srv/mediawiki/1.42/maintenance/run.php /srv/mediawiki/1.42/extensions/CreateWiki/maintenance/generateMissingCache.php --wiki=metawiki (END - exit=0)
* 05:01 MirahezeLSBot: [salt-user@mw152] sudo -u www-data php /srv/mediawiki/1.42/maintenance/run.php /srv/mediawiki/1.42/extensions/MirahezeMagic/maintenance/resetWikiCaches.php --wiki=metawiki (END - exit=0)
* 05:01 MirahezeLSBot: [agent@mwtask181] finished deploy of {'pull': 'config', 'config': True, 'force': True} to mw152 - SUCCESS in 1s
* 05:01 MirahezeLSBot: [agent@mwtask181] starting deploy of {'pull': 'config', 'config': True, 'force': True} to mw152
* 04:54 MirahezeLSBot: [@test151] finished deploy of {'folders': '1.43/extensions/MirahezeMagic'} to test151 - SUCCESS in 0s
* 04:54 MirahezeLSBot: [@test151] starting deploy of {'folders': '1.43/extensions/MirahezeMagic'} to test151
* 04:54 MirahezeLSBot: [@test151] finished deploy of {'folders': '1.42/extensions/MirahezeMagic'} to test151 - SUCCESS in 0s
* 04:54 MirahezeLSBot: [@test151] starting deploy of {'folders': '1.42/extensions/MirahezeMagic'} to test151
* 04:49 MirahezeLSBot: [salt-user@mw153] sudo -u www-data php /srv/mediawiki/1.42/maintenance/run.php /srv/mediawiki/1.42/extensions/CreateWiki/maintenance/generateMissingCache.php --wiki=metawiki (END - exit=65280)
* 04:49 MirahezeLSBot: [salt-user@mw153] sudo -u www-data php /srv/mediawiki/1.42/maintenance/run.php /srv/mediawiki/1.42/extensions/MirahezeMagic/maintenance/resetWikiCaches.php --wiki=metawiki (END - exit=65280)
* 04:49 MirahezeLSBot: [agent@mwtask181] finished deploy of {'pull': 'config', 'config': True, 'force': True} to mw153 - SUCCESS in 1s
* 04:49 MirahezeLSBot: [agent@mwtask181] starting deploy of {'pull': 'config', 'config': True, 'force': True} to mw153
* 04:46 MirahezeLSBot: [salt-user@mw153] Deleted JSON CreateWiki cache
* 04:45 MirahezeLSBot: [salt-user@mw153] sudo -u www-data php /srv/mediawiki/1.42/maintenance/run.php /srv/mediawiki/1.42/extensions/CreateWiki/maintenance/generateMissingCache.php --wiki=metawiki (END - exit=0)
* 04:45 MirahezeLSBot: [salt-user@mw153] sudo -u www-data php /srv/mediawiki/1.42/maintenance/run.php /srv/mediawiki/1.42/extensions/MirahezeMagic/maintenance/resetWikiCaches.php --wiki=metawiki (END - exit=0)
* 04:44 MirahezeLSBot: [universalomega@mwtask181] sudo rm /srv/mediawiki/cache/*.json
* 04:44 MirahezeLSBot: [universalomega@mwtask181] finished deploy of {'pull': 'config', 'config': True, 'force': True} to mwtask181 - SUCCESS in 0s
* 04:44 MirahezeLSBot: [universalomega@mwtask181] starting deploy of {'pull': 'config', 'config': True, 'force': True} to mwtask181
* 04:44 MirahezeLSBot: [universalomega@mwtask181] DEPLOY ABORTED: Canary check failed for publictestwiki.com@localhost
* 04:44 MirahezeLSBot: [universalomega@mwtask181] starting deploy of {'pull': 'config', 'config': True} to mwtask181
* 04:44 MirahezeLSBot: [agent@mwtask181] finished deploy of {'pull': 'config', 'config': True, 'force': True} to mw153 - SUCCESS in 1s
* 04:43 MirahezeLSBot: [agent@mwtask181] starting deploy of {'pull': 'config', 'config': True, 'force': True} to mw153
* 04:38 MirahezeLSBot: [universalomega@mwtask181] finished deploy of {'pull': 'errorpages', 'errorpages': True} to all - SUCCESS in 23s
* 04:38 MirahezeLSBot: [universalomega@mwtask181] starting deploy of {'pull': 'errorpages', 'errorpages': True} to all
* 04:37 MirahezeLSBot: [@mwtask171] finished deploy of {'folders': '1.42/extensions/MirahezeMagic'} to all - SUCCESS in 20s
* 04:37 MirahezeLSBot: [@mwtask171] starting deploy of {'folders': '1.42/extensions/MirahezeMagic'} to all
* 04:37 MirahezeLSBot: [universalomega@mwtask181] finished deploy of {'versions': '1.42', 'upgrade_extensions': ['CreateWiki', 'ManageWiki', 'MirahezeMagic']} to all - SUCCESS in 73s
* 04:36 MirahezeLSBot: [universalomega@mwtask181] starting deploy of {'versions': '1.42', 'upgrade_extensions': ['CreateWiki', 'ManageWiki', 'MirahezeMagic']} to all

## 2024-09-20

* 18:07 @paladox: set phorge171 ram back to 1gb. Fixed the issue.
* 12:45 @paladox: increase phroge171 ram to 2gb

## 2024-09-19

* 19:25 MirahezeLSBot: [reception@mwtask181] finished deploy of {'files': '../mediawiki/1.42/extensions/SemanticMediaWiki/.smw.json'} to all - SUCCESS in 28s
Expand Down

0 comments on commit aff6f6c

Please sign in to comment.