Charmed MySQL K8s
- Canonical
- Databases
Channel | Revision | Published | Runs on |
---|---|---|---|
8.0/stable | 180 | 02 Sep 2024 | |
8.0/stable | 181 | 02 Sep 2024 | |
8.0/candidate | 211 | 11 Dec 2024 | |
8.0/candidate | 210 | 11 Dec 2024 | |
8.0/beta | 211 | 09 Dec 2024 | |
8.0/beta | 210 | 09 Dec 2024 | |
8.0/edge | 211 | 09 Dec 2024 | |
8.0/edge | 210 | 09 Dec 2024 |
juju deploy mysql-k8s --channel 8.0/stable
Deploy Kubernetes operators easily with Juju, the Universal Operator Lifecycle Manager. Need a Kubernetes cluster? Install MicroK8s to create a full CNCF-certified Kubernetes system in under 60 seconds.
Platform:
Charm types “legacy” vs “modern”
Historically, there were several operators/charms to provide MySQL/MariaDB functionality: “MariaDB”, “OSM MariaDB”, “Percona Cluster” and “Mysql Innodb Cluster”. All of them are named “legacy” charms.
This “Charmed MySQL” operator is a modern “Charmed Operator SDK”-based charm to replace all legacy operators providing all juju-interfaces of legacy charms.
The legacy charm provided endpoints mysql
and mysql-root
(for the interface mysql
). The modern charm provides old endpoints as well + new endpoint database
(for the interface mysql_client
). Read more detail about the available endpoints/interfaces for VM and K8s charms.
Note: Please choose one endpoint to use. No need to relate all of them simultaneously!
The default track “latest” vs “8.0”
The default track has been switched from the latest
to 8.0
for both VM and K8s MySQL charms. It is to ensure all new deployments use a modern codebase. We strongly advise against using the latest track due to its implicit nature. In doing so, a future charm upgrade may result in a MySQL version incompatible with an integrated application. Track “8.0” guarantees MySQL 8.0 deployment only. The track latest
is closed to avoid confusion.
How to migrate from “legacy” to “modern” charm
The “modern” charm provides temporary support for the legacy interfaces:
-
quick try: relate the current application with new charm using endpoint
mysql
(set the channel to8.0/stable
). No extra changes necessary:
mysql:
charm: mysql-k8s
channel: 8.0/stable
trust: true
-
proper migration: migrate the application to the new interface “mysql_client”. The application will connect MySQL using “data_interfaces” library from “data-platform-libs” via endpoint
database
.
Warning: NO in-place upgrades possible! Legacy charm cannot be upgraded to Operator-framework-based one. To move DB data, the second/modern DB application must be launched nearby and data should be copied from “legacy” application to the “modern” one. Canonical Data Platform team will prepare the copy&paste guide. Please contact us if you need migration instructions.
Note: the trust
option must be enabled if Role Based Access Control (RBAC) is in use on your Kubernetes.
How to deploy old “legacy” mysql charm
Deploy the charm using the proper charm/channel:
osm-mariadb:
charm: charmed-osm-mariadb-k8s
channel: latest/stable
mysql:
charm: mysql-innodb-cluster
channel: 8.0/stable
Supported MySQL versions by modern charm
At the moment, both K8s and VM modern charms support MySQL 8.0 (based on Jammy/22.04 series) only. Please contact us if you need different versions/series.
Supported architectures: amd64, arm64, …
Currently, the charm supports architecture amd64
only. See the technical details in “Supported architectures”.
How to report issues and contact authors
The “modern charm” (from 8.0/stable
) is stored on GitHub, here is the link to report modern charm issues.
Do you have questions? Contact us!