mediawiki-dev

by joaquinito2051

Helm chartv0.4.7

A Helm chart for Mediawiki core in a development environment

About this chart

mediawiki-dev

mediawiki-dev is a helm chart for mediawiki/core. It is not suitable for production.

Installing the chart

mediawiki-dev has been tested with mariadb. It is expected to work with mysql or mariadb. Further work and testing are necessary for other database types. The database location, name, and password are the only requirements for the default chart installation (config.public.DB_SERVER, config.public.DB_NAME, config.private.DB_PASS).

Quick-install the mediawiki-dev chart using Helm

From this directory:

 helm install --set config.public.DB_SERVER="my_server" --set config.public.DB_NAME="my_name" --set config.private.DB_PASS="my_pass" .

Configuration

ParameterDescriptionDefault
docker.registryThe registry from which to pull the mediawiki/core imagedocker-registry.wikimedia.org
docker.pull_policyAlways, Never, or IfNotPresentIfNotPresent
resources.replicasThe number of instances to deploy1
main_app.imageThe image namewikimedia/mediawiki-core
main_app.versionThe image taglatest
main_app.portsThe container ports to expose[80]
main_app.commandThe command to run to override the entrypoint'["/bin/bash", "-c"]'
main_app.argsThe args to give to the commandimage default
main_app.requests.cpuCPU allocation100m
main_app.requests.memoryMemory allocation100Mi
main_app.limits.cpuCPU limit1.2
main_app.limits.memoryMemory limit500Mi
main_app.liveness_probe.tcpSocket.portThe port to use for healthchecks8080
main_app.readiness_probe.httpGet.pathThe endpoint to check for readiness/index.php/Special:BlankPage
main_app.readiness_probe.httpGet.portThe port to use for readiness checks8080
main_app.volumesVolumes to mount to the container. Useful for overriding LocalSettings or sharing local files[]
main_app.volumeMountsMounted volumes to make accesible[]
main_app.xdebug.enabledWhether to enable xdebugfalse
main_app.xdebug.remoteHostThe host that will be listening for xdebug''
main_app.xhprof.enabledWhether to enable xhproffalse
main_app.restrictedSecurityContext.enabledWhether to apply a production-like securityContext on all containers where possible.false
monitoring.enabledWhether to enable monitoringfalse
monitoring.image_versionThe monitoring image taglatest
service.deploymentproduction or minikubeminikube
service.portsPorts to expose[ { name: http, protoco: TCP, targetPort: 8080, port: 80, nodePort: null } ]
config.public.XDEBUG_CONFIGEnvironment variables for xdebug"remote_autostart=1 remote_enable=1 remote_handler=dbgp remote_host={{ .Values.main_app.xdebug.remoteHost }} remote_log=/tmp/xdebug_remote.log remote_mode=req remote_port=9000"
config.public.WIKI_NAMEThe name of the wiki"My Wiki"
config.public.WIKI_ADMINThe wiki admin username"admin"
config.public.DB_NAMEThe name of the database"my_wiki"
config.public.RESTBASE_NODEPORTThe nodeport of the restbase server""
config.public.MEDIAWIKI_DOMAINThe domain (used in restbase and parsoid config)"{{ .Release.Name }}"
config.public.RESTBASE_URLThe restbase connection string"http://restbase-{{ .Release.Name }}"
config.public.IS_RESTBASE_EXTERNALWhether restbase is running outside the clusterfalse
config.public.PARSOID_URLThe parsoid connection string"http://parsoid-{{ .Release.Name }}"
config.public.ENABLE_VISUAL_EDITORWhether to enable the visual editor"false"
config.public.DB_SERVERThe database connection string"{{ .Release.Name }}-mariadb"
config.private.WIKI_ADMIN_PASSThe wiki admin password"adminpass"
config.private.DB_PASSThe database password"password"
config.private.WG_SECRET_KEYA secret key"d964ce98b272c2115d5f4960563af8fb8f02ff968bbb0d62bdf4e1e4c18393ed"
config.private.WG_UPGRADE_KEYA key for upgradingaed8ffeb5b5fba9e

Localisation related settings

ParameterDescriptionDefault
main_app.usel10nCacheWhether to enable the localisation cachefalse
main_app.l10nNodePathThe directory on each node where localisation files will be stored. Must be specified if main_app.usel10nCache is truenull
main_app.owneruid:gid that the mediawiki container runs as. This is passed to chown to prepare a hostPath when main_app.usel10nCache is true"65533:65533"

Deploy mediawiki-dev with OpenTenant

Each tenant gets its own release of this chart, with its own namespace, secrets and domain. The builder below already has mediawiki-dev on a Hetzner server. Change the host, add apps from the marketplace, then copy the generated files. Providers and prices are samples, and nothing here is sent anywhere.

  1. Pick a serverConnect Hetzner, OVHcloud or AWS. The builder starts on Hetzner, the cheapest sample rate.
  2. Place the chartmediawiki-dev is pinned at v0.4.7 in opentenant.yaml. Drag more apps from the marketplace onto a rack.
  3. ApplySave opentenant.yaml and main.tf from the console, then run the commands below.
# opentenant.yaml, main.tf and dns.tf come from the builder below
opentenant validate opentenant.yaml
terraform init && terraform apply