settings

package
v1.6.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 28, 2023 License: MIT Imports: 7 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewBenchmarkConfiguration

func NewBenchmarkConfiguration() IConfiguration

func NewConfiguration

func NewConfiguration(path string, dockerized bool) (IConfiguration, error)

func NewTestConfiguration

func NewTestConfiguration() IConfiguration

Types

type Client

type Client struct {
	Id  string `yaml:"id"`
	Url string `yaml:"url"`
}

func (*Client) GetId

func (client *Client) GetId() string

func (*Client) GetUrl

func (client *Client) GetUrl() string

type Configuration

type Configuration struct {
	Dockerized  bool
	Environment string    `yaml:"environment"`
	Server      *Server   `yaml:"server"`
	Influx      *Influx   `yaml:"influx"`
	MySQL       *MySQL    `yaml:"mysql"`
	Clients     []*Client `yaml:"clients"`
}

func (*Configuration) GetClientsConfiguration

func (configuration *Configuration) GetClientsConfiguration() []IClientConfiguration

func (*Configuration) GetEnvironment

func (configuration *Configuration) GetEnvironment() string

func (*Configuration) GetInfluxConfiguration

func (configuration *Configuration) GetInfluxConfiguration() IInfluxConfiguration

func (*Configuration) GetMySQLConfiguration

func (configuration *Configuration) GetMySQLConfiguration() IMySqlConfiguration

func (*Configuration) GetPorts

func (configuration *Configuration) GetPorts() (int, int, int)

func (*Configuration) GetServerConfiguration

func (configuration *Configuration) GetServerConfiguration() IServerConfiguration

func (*Configuration) IsDevelopmentEnvironment

func (configuration *Configuration) IsDevelopmentEnvironment() bool

func (*Configuration) IsDockerized

func (configuration *Configuration) IsDockerized() bool

func (*Configuration) IsProductionEnvironment

func (configuration *Configuration) IsProductionEnvironment() bool

func (*Configuration) IsStagingEnvironment

func (configuration *Configuration) IsStagingEnvironment() bool

func (*Configuration) IsTestEnvironment

func (configuration *Configuration) IsTestEnvironment() bool

type Influx

type Influx struct {
	Enabled  bool     `yaml:"enabled"`
	Address  string   `yaml:"address"`
	Database string   `yaml:"database"`
	Username string   `yaml:"username"`
	Password string   `yaml:"password"`
	Replicas []string `yaml:"replicas"`
}

func (*Influx) GetAddress

func (influx *Influx) GetAddress() string

func (*Influx) GetDatabase

func (influx *Influx) GetDatabase() string

func (*Influx) GetPassword

func (influx *Influx) GetPassword() string

func (*Influx) GetReplicas

func (influx *Influx) GetReplicas() []string

func (*Influx) GetUsername

func (influx *Influx) GetUsername() string

func (*Influx) IsEnabled

func (influx *Influx) IsEnabled() bool

type MySQL

type MySQL struct {
	Address      string `yaml:"address"`
	Database     string `yaml:"database"`
	Username     string `yaml:"username"`
	Password     string `yaml:"password"`
	SkipPassword bool   `yaml:"skip_password"`
}

func (*MySQL) GetAddress

func (mysql *MySQL) GetAddress() string

func (*MySQL) GetDatabase

func (mysql *MySQL) GetDatabase() string

func (*MySQL) GetPassword

func (mysql *MySQL) GetPassword() string

func (*MySQL) GetUsername

func (mysql *MySQL) GetUsername() string

func (*MySQL) IsPasswordSkipped

func (mysql *MySQL) IsPasswordSkipped() bool

func (*MySQL) SetAddress

func (mysql *MySQL) SetAddress(address string)

func (*MySQL) SetDatabase

func (mysql *MySQL) SetDatabase(database string)

func (*MySQL) SetPassword

func (mysql *MySQL) SetPassword(password string)

func (*MySQL) SetUsername

func (mysql *MySQL) SetUsername(username string)

type Ports

type Ports struct {
	Active      int `yaml:"active"`
	Passive     int `yaml:"passive"`
	Diagnostics int `yaml:"diagnostics"`
}

func (*Ports) GetActive

func (ports *Ports) GetActive() int

func (*Ports) GetDiagnostics

func (ports *Ports) GetDiagnostics() int

func (*Ports) GetPassive

func (ports *Ports) GetPassive() int

type Server

type Server struct {
	FQDN        string `yaml:"fqdn"`
	Protocol    string `yaml:"protocol"`
	Ports       *Ports `yaml:"ports"`
	TLS         *TLS   `yaml:"tls"`
	BuildNumber int32  `yaml:"build_number"`
	HashKey     string `yaml:"hash_key"`
	BlockKey    string `yaml:"block_key"`
}

func (*Server) GetBlockKey

func (server *Server) GetBlockKey() string

func (*Server) GetBuildNumber

func (server *Server) GetBuildNumber() int32

func (*Server) GetFQDN

func (server *Server) GetFQDN() string

func (*Server) GetHashKey

func (server *Server) GetHashKey() string

func (*Server) GetPortConfiguration

func (server *Server) GetPortConfiguration() IPortConfiguration

func (*Server) GetProtocol

func (server *Server) GetProtocol() string

func (*Server) GetTLSConfiguration

func (server *Server) GetTLSConfiguration() ITLSConfiguration

func (*Server) SetBuildNumber

func (server *Server) SetBuildNumber(value int32)

type TLS

type TLS struct {
	KeyFile  string `yaml:"key_file"`
	CertFile string `yaml:"cert_file"`
}

func (*TLS) GetCertFile

func (tls *TLS) GetCertFile() string

func (*TLS) GetKeyFile

func (tls *TLS) GetKeyFile() string

func (*TLS) IsEnabled

func (tls *TLS) IsEnabled() bool

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL