apiVersion: v1
kind: ConfigMap
metadata:
  labels:
    app: mysql-config
  name: mysql-config
data:
  my.cnf: |
    # Apply this config only on the master.
    [client]
    default-character-set=utf8mb4

    [mysql]
    default-character-set=utf8mb4

    [mysqld]

    default_authentication_plugin= mysql_native_password

    default-time-zone='+8:00'
    character-set-client-handshake=FALSE
    character-set-server=utf8mb4
    collation-server=utf8mb4_unicode_ci
    init_connect='SET NAMES utf8mb4 COLLATE utf8mb4_unicode_ci'