Relation endpoints

See Integrations.

Database

The database relation endpoint is a mandatory relation that shares connection information for a MySQL database with MediaWiki, providing storage for MediaWiki. You may choose to directly connect to a MySQL charm, or use a MySQL router charm to connect to an existing MySQL cluster.

Example database integrate command:

juju integrate mediawiki-k8s mysql-k8s:database

Grafana dashboard

The grafana dashboard relation is part of the COS relation, providing a pre-built Grafana dashboard tailored to fit the needs of the MediaWiki charm. The provided dashboard requires both the logging relation and the metrics-endpoint relation to be established to the COS deployment. Modifications to the dashboard can be made but will not be persisted upon restart or redeployment of the charm. Learn more about COS here.

Example grafana-dashboard integrate command:

juju integrate mediawiki-k8s grafana-k8s

Logging

The logging relation is a part of the COS relation to enhance logging observability. Logging relation through the loki_push_api interface forwards the standard outputs of all workloads as well as /var/log/mediawiki/logs.log to Loki. This can then be queried through the Loki API or easily visualized through Grafana. Learn more about COS here.

Example logging integrate command:

juju integrate mediawiki-k8s loki-k8s

Metrics endpoint

The metrics-endpoint relation exposes workload metrics for supported charms in the open metrics format. Apache metrics are collected from the internal /server-status endpoint using Apache exporter and then published through this relation. The /server-status route is not externally exposed and is only reachable from within the same Kubernetes pod. Metrics from the git-sync sidecar are also published through the metrics-endpoint relation. This relation is part of the COS observability integration. Learn more about COS here.

Example metrics-endpoint integrate command:

juju integrate mediawiki-k8s prometheus-k8s

See also

Read more about the metrics provided by the MediaWiki charm on the metrics reference documentation.

OAuth

Warning

While the oauth relation will function while configuring MediaWiki to use a HTTP or protocol-relative URL, it is highly recommended to explicitly allow only HTTPS in a production environment.

The oauth relation connects with an OAuth provider to allow for easy setup of OAuth based SSO.

This is accomplished using the OpenID Connect MediaWiki extension, which is included with the MediaWiki charm. The OpenID Connect extension can be further configured through the oauth-extra-scopes and local-settings configuration options.

Example oauth integrate command:

juju integrate mediawiki-k8s hydra:oauth

See also

Read more about the Canonical Identity Platform.

Redis

The redis relation connects MediaWiki to a Redis instance, allowing for caching of MediaWiki data in Redis. This can improve the performance of your MediaWiki instance.

Example redis integrate command:

juju integrate mediawiki-k8s redis-k8s:redis

See also

Read more about how MediaWiki uses Redis as an object cache backend: Redis

SAML

The saml relation connects MediaWiki to a SAML Identity Provider (IdP) through the saml-integrator charm, enabling SAML based SSO.

This is accomplished using the SimpleSAMLphp MediaWiki extension, which is included with the MediaWiki charm. The SimpleSAMLphp extension uses the PluggableAuth framework for authentication.

Warning

While the saml relation will function while configuring MediaWiki to use a HTTP or protocol-relative URL, it is highly recommended to explicitly allow only HTTPS in a production environment.

Important

The Redis relation is required when using SAML, as SimpleSAMLphp uses Redis as its session store.

Example saml integrate command:

juju integrate mediawiki-k8s saml-integrator:saml

See also

Read more about SimpleSAMLphp and the Canonical Identity Platform.

S3 parameters

The s3-parameters relation endpoint provides MediaWiki with the necessary information to upload files to an S3-compatible object storage service, allowing for user uploads of files. This relation is only required if you wish to allow file uploads in your MediaWiki instance.

The MediaWiki charm uses the included AWS MediaWiki extension for this functionality.

Important

For security reasons and separation of load, the MediaWiki charm will not act as a reverse proxy for the S3 compatible object storage service. You need to separately ensure that your users can reach and read from your configured object storage service.

To configure which endpoint MediaWiki will redirect users to in order to serve file uploads, configure the $wgAWSBucketDomain parameter in the local-settings configuration option.

Refer to the AWS MediaWiki extension documentation for more information on how to configure the AWS extension.

Example s3-parameters integrate command:

juju integrate mediawiki-k8s s3-integrator:s3-credentials

SMTP

The smtp relation connects MediaWiki to SMTP relay configuration through the smtp-integrator charm, enabling outgoing emails for features such as account recovery and notifications.

When available, the charm configures MediaWiki’s SMTP settings including relay host, port, authentication, and optional sender address. If relation data is incomplete or malformed, outgoing email is disabled until valid data is provided.

Example smtp integrate command:

juju integrate mediawiki-k8s smtp-integrator:smtp

Traefik route

The traefik_route relation allows MediaWiki to connect to a Traefik charm deployment to automatically configure routing from outside the Kubernetes cluster to MediaWiki.

Example traefik_route integrate command:

juju integrate mediawiki-k8s traefik-k8s:traefik_route