Documentation

Index

Constants

View Source
const (
	EnvKeyNodeName      = "BAETYL_NODE_NAME"
	EnvKeyNodeNamespace = "BAETYL_NODE_NAMESPACE"
)

Variables

This section is empty.

Functions

func DownloadConfig

func DownloadConfig(cli *http.Client, objectPath string, cfg *specv1.Configuration) error

func FilterConfig

func FilterConfig(cfg *specv1.Configuration)

func PrepareApp

func PrepareApp(hostPath, objectPath string, app *specv1.Application, cfgs map[string]specv1.Configuration) error

    TODO: move to the right place

    Types

    type Sync

    type Sync interface {
    	Start()
    	Close()
    	Report(r v1.Report) (v1.Desire, error)
    	SyncResource(v1.AppInfo) error
    	SyncApps(infos []v1.AppInfo) (map[string]v1.Application, error)
    }

      go:generate mockgen -destination=../mock/sync.go -package=mock github.com/baetyl/baetyl/sync Sync

      func NewSync

      func NewSync(cfg config.Config, store *bh.Store, nod *node.Node, helper helper.Helper) (Sync, error)

        NewSync create a new sync