Documentation ¶
Index ¶
- Constants
- Variables
- type BotClientPtr
- type BotClientT
- type BotClientsT
- type ConfigT
- func (cfg ConfigT) CRLListenAddress() string
- func (cfg ConfigT) CertKit() stonelizard.AuthT
- func (cfg ConfigT) GetHost() []Host
- func (cfg ConfigT) HttpsClient(tmout time.Duration) *http.Client
- func (cfg ConfigT) ListenAddress() string
- func (cfg *ConfigT) LoadClientCert() error
- func (cfg *ConfigT) NewSshClientConfig(privKeyPath string) error
- func (cfg ConfigT) PageNotFound() []byte
- func (cfg *ConfigT) PingAt() error
- func (cfg *ConfigT) Start(cmdline string, dbgLevel int) error
- func (cfg ConfigT) Stop() error
- type Host
- type Hosts
- type MasterbotG
- type ServiceT
- type StatusT
- type Timeout
Constants ¶
View Source
const ( BotStatStopped string = "S" BotStatRunning string = "R" BotStatPaused string = "P" //Used to disable BotStatUnreachable string = "U" )
View Source
const SSHPort string = "22"
Variables ¶
View Source
var ErrCreatingSession = errors.New("Error failed creating session")
View Source
var ErrDialingToBot = errors.New("Error failed dialing to bot")
View Source
var ErrFailedPingingBot = errors.New("Error failed pinging bot")
View Source
var ErrFailedStartingBot = errors.New("Error failed to starting bot")
View Source
var ErrLoadingCliCerts = errors.New("Error Loading client certificates")
View Source
var ErrNoBotsToPing = errors.New("Error no bots to ping at")
View Source
var ErrParsingConfig = errors.New("Error parsing config.json")
View Source
var ErrParsingSSHKeys = errors.New("Error parsing SSH keys (id_dsa)")
View Source
var ErrReadingConfig = errors.New("Error reading config.json")
View Source
var ErrReadingSSHKeys = errors.New("Error reading SSH keys (id_dsa)")
View Source
var ErrStatusStoppingBot = errors.New("Error of status stopping bot")
View Source
var ErrStoppingBot = errors.New("Error stopping bot")
View Source
var Kairos *cron.Cron
View Source
var ReBotSearchInputParameters *regexp.Regexp = regexp.MustCompile("#([\\pL0-9_]+)")
View Source
var ReBotSearchOutputData *regexp.Regexp = regexp.MustCompile("\\$([\\pL0-9_]+)")
Functions ¶
This section is empty.
Types ¶
type BotClientPtr ¶
type BotClientPtr *BotClientT
type BotClientT ¶
type BotClientT struct { BinDir string `json:"bindir"` BinName string `json:"binname"` Listen string `json:"listen"` Host Hosts `json:"host"` SysUser string `json:"sysuser"` WorkDir string `json:"workdir"` SearchPath string `json:"searchpath"` SearchPathRE *regexp.Regexp `json:"-"` StatusT CronPingId []int `json:"-"` CronPingFn []func() `json:"-"` }
func (*BotClientT) PingAt ¶
func (s *BotClientT) PingAt(botId string, botInstance int, cfg *ConfigT) error
type BotClientsT ¶
type BotClientsT map[string]BotClientPtr
func (*BotClientsT) Start ¶
func (bc *BotClientsT) Start(config *ConfigT, cmdline string, debugLevel int)
func (*BotClientsT) UnmarshalJSON ¶
func (bc *BotClientsT) UnmarshalJSON(buf []byte) error
type ConfigT ¶
type ConfigT struct { Id string `json:"id"` Host Hosts `json:"host"` SysUser string `json:"sysuser"` WorkDir string `json:"workdir"` Listen string `json:"listen"` CrlListen string `json:"crllisten"` PageNotFoundPath string `json:"pageNotFound"` Pem string `json:"pem"` BinDir string `json:"bindir"` BinName string `json:"binname"` ClientCert tls.Certificate `json:"-"` ClientCA *x509.CertPool `json:"-"` Bot BotClientsT `json:"bot,omitempty"` SshClientConfig *ssh.ClientConfig `json:"-"` BotPingRate string `json:"botpingrate,omitempty"` BotCommTimeout Timeout `json:"botcommtimeout,omitempty"` HttpsPingClient *http.Client `json:"-"` HttpsStopClient *http.Client `json:"-"` Certkit stonelizard.AuthT `json:"-"` Transport *http.Transport `rset:"-"` }
func (ConfigT) CRLListenAddress ¶
func (ConfigT) CertKit ¶
func (cfg ConfigT) CertKit() stonelizard.AuthT
func (ConfigT) ListenAddress ¶
func (*ConfigT) LoadClientCert ¶
func (*ConfigT) NewSshClientConfig ¶
func (ConfigT) PageNotFound ¶
type MasterbotG ¶
var Goose MasterbotG
type ServiceT ¶
type ServiceT struct {
// contains filtered or unexported fields
}
func (ServiceT) Stop ¶
func (svc ServiceT) Stop() stonelizard.Response
Source Files ¶
- BotClientT.PingAt.go
- BotClientT.Start.go
- BotClientT.Stop.go
- BotClientsT.Start.go
- BotClientsT.UnmarshalJSON.go
- ConfigT.CRLListenAddress.go
- ConfigT.CertKit.go
- ConfigT.GetHost.go
- ConfigT.HttpsClient.go
- ConfigT.ListenAddress.go
- ConfigT.NewSSHClientConfig.go
- ConfigT.PageNotFound.go
- ConfigT.PingAt.go
- ConfigT.Start.go
- ConfigT.Stop.go
- LoadClientCert.go
- New.go
- ReadConfig.go
- ServiceT.GetConfig.go
- ServiceT.Stop.go
- Timeout.MarshalJSON.go
- Timeout.Set.go
- Timeout.String.go
- Timeout.UnmarshalJSON.go
- decls.go
- defs.go
- init.go
Click to show internal directories.
Click to hide internal directories.