Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var (
// MysqlServerIDOffset represents the offset with which all server ids are shifted from 0
MysqlServerIDOffset = 100
)
Functions ¶
func RunCloneCommand ¶
RunCloneCommand clone the data from source. nolint: gocyclo
func RunConfigCommand ¶
RunConfigCommand generates my.cnf, client.cnf and 10-dynamic.cnf files.
func RunSidecarCommand ¶
RunSidecarCommand is the main command, and represents the runtime helper that configures the mysql server
func RunTakeBackupCommand ¶
RunTakeBackupCommand starts a backup command
Types ¶
type Config ¶
type Config struct { // Hostname represents the pod hostname Hostname string // ClusterName is the MySQL cluster name ClusterName string // Namespace represents the namespace where the pod is in Namespace string // ServiceName is the name of the headless service ServiceName string // InitBucketURL represents the init bucket to initialize mysql InitBucketURL string // OrchestratorURL is the URL to connect to orchestrator OrchestratorURL string // backup user and password for http endpoint BackupUser string BackupPassword string // replication user and password ReplicationUser string ReplicationPassword string // metrics exporter user and password MetricsUser string MetricsPassword string // orchestrator credentials OrchestratorUser string OrchestratorPassword string }
Config contains information related with the pod.
func NewConfig ¶
func NewConfig() *Config
NewConfig returns a pointer to Config configured from environment variables
func (*Config) ClusterFQDN ¶
ClusterFQDN returns the cluster FQ Name of the cluster from which the node belongs
func (*Config) FQDNForServer ¶
FQDNForServer returns the pod hostname for given MySQL server id
func (*Config) MasterFQDN ¶
MasterFQDN the FQ Name of the cluster's master
Click to show internal directories.
Click to hide internal directories.