Page MenuHomePhabricator

Consider setting some configuration variables by default in the MediaWiki container
Closed, ResolvedPublic

Description

As described in T115432: Get MW_CONFIG_FILE from env to facilitate virtual hosting, we could do something similar to prepend a settings file at /docker/DockerSettings.php, this could be useful for setting up config like T246942.

The file could also be a useful place to take environment variables defined in .env or in docker-compose.override.yml and translate them to MediaWiki config variables.

Event Timeline

Change 582498 had a related patch set uploaded (by Kosta Harlan; owner: Kosta Harlan):
[releng/dev-images@master] Provide support for setting default configuration in dev image

https://gerrit.wikimedia.org/r/582498

Change 582499 had a related patch set uploaded (by Kosta Harlan; owner: Kosta Harlan):
[mediawiki/core@master] Allow setting MW_CONFIG_FILE via environment variable

https://gerrit.wikimedia.org/r/582499

The convention for this, as established by the PlatformSettings RFC (T182020) is for the MW provider (in this case the dev container) to create a one-line LocalSettings.php file that explicitly includes any shared or prepended settings from wherever they are kept.

Would that work here?

I wrote in the patch that I'd rather have one less step, but if the patch is rejected then we can work around that either with a LocalSettings.php that requires /docker/DockerSettings.php or with includes/PlatformSettings.php

Change 582499 abandoned by Kosta Harlan:
Allow setting MW_CONFIG_FILE via environment variable

Reason:
per comments

https://gerrit.wikimedia.org/r/582499

Change 582498 merged by Brennen Bearnes:
[releng/dev-images@master] Provide support for setting default configuration in dev image

https://gerrit.wikimedia.org/r/582498

brennen claimed this task.

I think this can be closed - please reopen if I'm mistaken.