Versions in this module Expand all Collapse all v1 v1.2.0 Apr 3, 2024 Changes in this version + func CreateControllerDatabase(host, user, password, provider, dbName string, port int) + type Auth struct + ControllerClient string + ControllerSecret string + Realm string + RealmKey string + SSL string + URL string + ViewerClient string type ControllerConfig + Auth Auth v1.1.0 Feb 19, 2024 Changes in this version type IofogUser + SubscriptionKey string v1.0.0 Jun 20, 2023 Changes in this version + func GetLocalContainerName(t string, isSystem bool) string + func IsVerbose() bool + func SetVerbosity(verbose bool) + func Verbose(msg string) + func WaitForControllerAPI(endpoint string) (err error) + type Agent interface + Bootstrap func() error + type AgentProcedures struct + Deps Entrypoint + Install Entrypoint + Uninstall Entrypoint + type Controller struct + func NewController(options *ControllerOptions) (*Controller, error) + func (ctrl *Controller) CopyScript(srcDir, filename, destDir string) (err error) + func (ctrl *Controller) Install() (err error) + func (ctrl *Controller) SetControllerExternalDatabase(host, user, password, provider, databaseName string, port int) + func (ctrl *Controller) Stop() (err error) + func (ctrl *Controller) Uninstall() (err error) + type ControllerConfig struct + Database Database + EcnViewerPort int + PidBaseDir string + Replicas int32 + User IofogUser + type ControllerOptions struct + EcnViewerPort int + Host string + PidBaseDir string + Port int + PrivKeyFilename string + Repo string + SystemMicroservices RemoteSystemMicroservices + Token string + User string + Version string + type Credentials struct + Password string + User string + type Database struct + DatabaseName string + Host string + Password string + Port int + Provider string + User string + type Entrypoint struct + Args []string + Name string + type ExecResult struct + ExitCode int + StdErr string + StdOut string + type IofogUser struct + Email string + Name string + Password string + Surname string + type Kubernetes struct + func NewKubernetes(configFilename, namespace string) (*Kubernetes, error) + func (k8s *Kubernetes) CreateControlPlane(conf *ControllerConfig) (endpoint string, err error) + func (k8s *Kubernetes) DeleteControlPlane() error + func (k8s *Kubernetes) ExistsInNamespace(namespace string) error + func (k8s *Kubernetes) GetControllerEndpoint() (endpoint string, err error) + func (k8s *Kubernetes) GetControllerPods() (podNames []Pod, err error) + func (k8s *Kubernetes) SetControllerImage(image string) + func (k8s *Kubernetes) SetControllerService(svcType, ip string) + func (k8s *Kubernetes) SetOperatorImage(image string) + func (k8s *Kubernetes) SetPortManagerImage(image string) + func (k8s *Kubernetes) SetProxyImage(image string) + func (k8s *Kubernetes) SetProxyService(svcType, ip string) + func (k8s *Kubernetes) SetRouterImage(image string) + func (k8s *Kubernetes) SetRouterService(svcType, ip string) + type LocalAgent struct + func NewLocalAgent(localAgentConfig *LocalAgentConfig, client *LocalContainer) *LocalAgent + func (agent *LocalAgent) Bootstrap() error + func (agent *LocalAgent) Configure(controllerEndpoint string, user IofogUser) (string, error) + type LocalAgentConfig struct + Name string + func NewLocalAgentConfig(name, image string, ctrlConfig *LocalContainerConfig, credentials Credentials, ...) *LocalAgentConfig + type LocalContainer struct + func NewLocalContainerClient() (*LocalContainer, error) + func (lc *LocalContainer) CleanContainer(name string) error + func (lc *LocalContainer) CleanContainerByID(id string) error + func (lc *LocalContainer) CopyToContainer(name, source, dest string) (err error) + func (lc *LocalContainer) DeployContainer(containerConfig *LocalContainerConfig) (string, error) + func (lc *LocalContainer) ExecuteCmd(name string, cmd []string) (execResult ExecResult, err error) + func (lc *LocalContainer) GetContainerByName(name string) (types.Container, error) + func (lc *LocalContainer) GetContainerIP(name string) (ip string, err error) + func (lc *LocalContainer) GetLocalControllerEndpoint() (controllerEndpoint string, err error) + func (lc *LocalContainer) GetLogsByName(name string) (stdout, stderr string, err error) + func (lc *LocalContainer) ListContainers() ([]types.Container, error) + func (lc *LocalContainer) WaitForCommand(containerName string, condition *regexp.Regexp, command ...string) error + type LocalContainerConfig struct + Binds []string + ContainerName string + Credentials Credentials + DefaultImage string + Host string + Image string + NetworkMode string + Ports []port + Privileged bool + func NewLocalControllerConfig(image string, credentials Credentials) *LocalContainerConfig + type LocalContainerPort struct + Port string + Protocol string + type LocalControllerConfig struct + ContainerMap map[string]*LocalContainerConfig + type Pod struct + Name string + Status string + type RemoteAgent struct + func NewRemoteAgent(user, host string, port int, privKeyFilename, agentName, agentUUID string) (*RemoteAgent, error) + func (agent *RemoteAgent) Bootstrap() error + func (agent *RemoteAgent) Configure(controllerEndpoint string, user IofogUser) (string, error) + func (agent *RemoteAgent) CustomizeProcedures(dir string, procs *AgentProcedures) error + func (agent *RemoteAgent) Deprovision() (err error) + func (agent *RemoteAgent) Prune() (err error) + func (agent *RemoteAgent) SetRepository(repo, token string) + func (agent *RemoteAgent) SetVersion(version string) + func (agent *RemoteAgent) Stop() (err error) + func (agent *RemoteAgent) Uninstall() (err error) + type RemoteSystemImages struct + ARM string + X86 string + type RemoteSystemMicroservices struct + Proxy RemoteSystemImages + Router RemoteSystemImages