Recent versions of MediaWiki use a run.php launcher for maintenance scripts.
That means our mw wrapper should run rlwrap php /srv/mediawiki/maintenance/run.php ... instead of directly the relevant script
$ mw update agora ******************************************************************************* NOTE: Do not run maintenance scripts directly, use maintenance/run.php instead! Running scripts directly has been deprecated in MediaWiki 1.40. It may not work for some (or any) scripts in the future. *******************************************************************************
mw is actually a shell script to run the script against the right wiki.
The last line does runs the final command:
https://devcentral.nasqueron.org/source/operations/browse/main/roles/saas-mediawiki/software/files/mw.sh.jinja$103