Skip to content

🤖 Sidecar agent for MariaDB that co-operates with mariadb-operator

License

Notifications You must be signed in to change notification settings

matthieugusmini/agent

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

35 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

mariadb

CI Release Go Report Card Go Reference Slack

🤖 agent

Sidecar agent for MariaDB that co-operates with mariadb-operator. Remotely manage Galera via HTTP instead of configuration *.cnf files.

  • HTTP API to manage Galera and expose the MariaDB state to mariadb-operator
  • Query and update Galera state without mounting /var/lib/mysql/grastate.dat
  • Perform Galera cluster recovery remotely
  • Bootstrap new Galera cluster as a result of the cluster recovery
  • Idiomatic Go HTTP client pkg/client
  • Authentication using Kubernetes service accounts via TokenReview API

How to use it

Specify the agent image in the MariaDB spec.galera.agent field.

apiVersion: mariadb.mmontes.io/v1alpha1
kind: MariaDB
metadata:
  name: mariadb-galera
spec:
  ...
  image:
    repository: mariadb
    tag: "10.11.3"
    pullPolicy: IfNotPresent
  port: 3306
  replicas: 3

  galera:
    sst: mariabackup
    replicaThreads: 1

    agent:
      image:
        repository: ghcr.io/mariadb-operator/agent
        tag: "v0.0.2"
        pullPolicy: IfNotPresent
      port: 5555
      kubernetesAuth:
        enabled: true
        authDelegatorRoleName: mariadb-galera-auth
      gracefulShutdownTimeout: 5s
  ...

HTTP API

You can consume the agent API using the pkg/client. Alternatively, take a look at our Postman collection.

Run in Postman

About

🤖 Sidecar agent for MariaDB that co-operates with mariadb-operator

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Go 91.4%
  • Makefile 6.2%
  • Shell 1.8%
  • Dockerfile 0.6%