instance

package
v0.0.19 Latest Latest
Warning

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

Go to latest
Published: Nov 14, 2024 License: Apache-2.0 Imports: 22 Imported by: 0

Documentation

Index

Constants

View Source
const DummyBranch = "dummy"

Variables

This section is empty.

Functions

func EnsureDir

func EnsureDir(dirname string) error

func Exists

func Exists(filepath string) bool

Types

type ChildChoreoInstance

type ChildChoreoInstance struct {
	// contains filtered or unexported fields
}

func (*ChildChoreoInstance) AddAPIs

func (r *ChildChoreoInstance) AddAPIs(apiStore *api.APIStore)

func (*ChildChoreoInstance) AddChildChoreoInstance

func (r *ChildChoreoInstance) AddChildChoreoInstance(newchildchoreoinstance ChoreoInstance) error

func (*ChildChoreoInstance) AddLibraries

func (r *ChildChoreoInstance) AddLibraries(libraries ...*choreov1alpha1.Library)

func (*ChildChoreoInstance) AddReconcilers

func (r *ChildChoreoInstance) AddReconcilers(reconcilers ...*choreov1alpha1.Reconciler)

func (*ChildChoreoInstance) CommitWorktree

func (r *ChildChoreoInstance) CommitWorktree(msg string) (*choreopb.Commit_Response, error)

func (*ChildChoreoInstance) Destroy

func (r *ChildChoreoInstance) Destroy() error

func (*ChildChoreoInstance) GetAPIClient

func (r *ChildChoreoInstance) GetAPIClient() resourceclient.Client

func (*ChildChoreoInstance) GetAPIs

func (r *ChildChoreoInstance) GetAPIs() *api.APIStore

func (*ChildChoreoInstance) GetAnnotationVal

func (r *ChildChoreoInstance) GetAnnotationVal() string

func (*ChildChoreoInstance) GetChildren

func (r *ChildChoreoInstance) GetChildren() []ChoreoInstance

func (*ChildChoreoInstance) GetChoreoInstanceName

func (r *ChildChoreoInstance) GetChoreoInstanceName() string

func (*ChildChoreoInstance) GetCommit

func (r *ChildChoreoInstance) GetCommit() *object.Commit

func (*ChildChoreoInstance) GetConfig

func (*ChildChoreoInstance) GetDBPath

func (r *ChildChoreoInstance) GetDBPath() string

func (*ChildChoreoInstance) GetInternalAPIStore

func (r *ChildChoreoInstance) GetInternalAPIStore() *api.APIStore

func (*ChildChoreoInstance) GetLibraries

func (r *ChildChoreoInstance) GetLibraries() []*choreov1alpha1.Library

func (*ChildChoreoInstance) GetName

func (r *ChildChoreoInstance) GetName() string

func (*ChildChoreoInstance) GetPath

func (r *ChildChoreoInstance) GetPath() string

func (*ChildChoreoInstance) GetPathInRepo

func (r *ChildChoreoInstance) GetPathInRepo() string

func (*ChildChoreoInstance) GetReconcilers

func (r *ChildChoreoInstance) GetReconcilers() []*choreov1alpha1.Reconciler

func (*ChildChoreoInstance) GetRepo

func (*ChildChoreoInstance) GetRepoPath

func (r *ChildChoreoInstance) GetRepoPath() string

func (*ChildChoreoInstance) GetTempPath

func (r *ChildChoreoInstance) GetTempPath() string

func (*ChildChoreoInstance) GetUpstreamRef

func (r *ChildChoreoInstance) GetUpstreamRef() *choreov1alpha1.UpstreamRef

func (*ChildChoreoInstance) InitAPIs

func (r *ChildChoreoInstance) InitAPIs()

func (*ChildChoreoInstance) InitChildren

func (r *ChildChoreoInstance) InitChildren()

func (*ChildChoreoInstance) InitLibraries

func (r *ChildChoreoInstance) InitLibraries()

func (*ChildChoreoInstance) InitReconcilers

func (r *ChildChoreoInstance) InitReconcilers()

func (*ChildChoreoInstance) IsRootInstance

func (r *ChildChoreoInstance) IsRootInstance() bool

func (*ChildChoreoInstance) PushBranch

func (r *ChildChoreoInstance) PushBranch(branch string) (*choreopb.Push_Response, error)

func (*ChildChoreoInstance) SchemaLoader

func (r *ChildChoreoInstance) SchemaLoader() *schemaloader.SchemaLoader

func (*ChildChoreoInstance) SchemaStore

func (r *ChildChoreoInstance) SchemaStore() schemastore.Store

type ChoreoInstance

type ChoreoInstance interface {
	GetChoreoInstanceName() string
	InitChildren()
	AddChildChoreoInstance(ChoreoInstance) error
	GetChildren() []ChoreoInstance
	GetName() string
	GetRepo() repository.Repository
	GetRepoPath() string
	GetPath() string
	GetTempPath() string
	GetPathInRepo() string
	GetDBPath() string
	GetConfig() *genericclioptions.ChoreoConfig
	GetInternalAPIStore() *api.APIStore // provides the internal apistore, only relevant for rootInstance
	GetCommit() *object.Commit
	GetAPIClient() resourceclient.Client
	GetAnnotationVal() string
	Destroy() error
	CommitWorktree(msg string) (*choreopb.Commit_Response, error)
	PushBranch(branch string) (*choreopb.Push_Response, error)
	GetUpstreamRef() *choreov1alpha1.UpstreamRef
	IsRootInstance() bool

	InitAPIs()
	GetAPIs() *api.APIStore
	AddAPIs(*api.APIStore)
	InitLibraries()
	GetLibraries() []*choreov1alpha1.Library
	AddLibraries(...*choreov1alpha1.Library)
	InitReconcilers()
	GetReconcilers() []*choreov1alpha1.Reconciler
	AddReconcilers(...*choreov1alpha1.Reconciler)

	SchemaStore() schemastore.Store
	SchemaLoader() *schemaloader.SchemaLoader
}

func NewChildChoreoInstance

func NewChildChoreoInstance(ctx context.Context, repo repository.Repository, upstreamRef *choreov1alpha1.UpstreamRef, cfg *genericclioptions.ChoreoConfig, commit *object.Commit, annotationVal string) (ChoreoInstance, error)

func NewRootChoreoInstance

func NewRootChoreoInstance(ctx context.Context, config *Config) (ChoreoInstance, error)

type Config

type Config struct {
	Path       string
	Repo       repository.Repository
	Commit     *object.Commit
	PathInRepo string
	Cfg        *genericclioptions.ChoreoConfig
}

type RootChoreoInstance

type RootChoreoInstance struct {
	// contains filtered or unexported fields
}

func (*RootChoreoInstance) AddAPIs

func (r *RootChoreoInstance) AddAPIs(apiStore *api.APIStore)

func (*RootChoreoInstance) AddChildChoreoInstance

func (r *RootChoreoInstance) AddChildChoreoInstance(newchildchoreoinstance ChoreoInstance) error

func (*RootChoreoInstance) AddLibraries

func (r *RootChoreoInstance) AddLibraries(libraries ...*choreov1alpha1.Library)

func (*RootChoreoInstance) AddReconcilers

func (r *RootChoreoInstance) AddReconcilers(reconcilers ...*choreov1alpha1.Reconciler)

func (*RootChoreoInstance) CommitWorktree

func (r *RootChoreoInstance) CommitWorktree(msg string) (*choreopb.Commit_Response, error)

func (*RootChoreoInstance) Destroy

func (r *RootChoreoInstance) Destroy() error

func (*RootChoreoInstance) GetAPIClient

func (r *RootChoreoInstance) GetAPIClient() resourceclient.Client

func (*RootChoreoInstance) GetAPIs

func (r *RootChoreoInstance) GetAPIs() *api.APIStore

func (*RootChoreoInstance) GetAnnotationVal

func (r *RootChoreoInstance) GetAnnotationVal() string

func (*RootChoreoInstance) GetChildren

func (r *RootChoreoInstance) GetChildren() []ChoreoInstance

func (*RootChoreoInstance) GetChoreoInstanceName

func (r *RootChoreoInstance) GetChoreoInstanceName() string

func (*RootChoreoInstance) GetCommit

func (r *RootChoreoInstance) GetCommit() *object.Commit

func (*RootChoreoInstance) GetConfig

func (*RootChoreoInstance) GetDBPath

func (r *RootChoreoInstance) GetDBPath() string

func (*RootChoreoInstance) GetInternalAPIStore

func (r *RootChoreoInstance) GetInternalAPIStore() *api.APIStore

func (*RootChoreoInstance) GetLibraries

func (r *RootChoreoInstance) GetLibraries() []*choreov1alpha1.Library

func (*RootChoreoInstance) GetName

func (r *RootChoreoInstance) GetName() string

func (*RootChoreoInstance) GetPath

func (r *RootChoreoInstance) GetPath() string

func (*RootChoreoInstance) GetPathInRepo

func (r *RootChoreoInstance) GetPathInRepo() string

func (*RootChoreoInstance) GetReconcilers

func (r *RootChoreoInstance) GetReconcilers() []*choreov1alpha1.Reconciler

func (*RootChoreoInstance) GetRepo

func (*RootChoreoInstance) GetRepoPath

func (r *RootChoreoInstance) GetRepoPath() string

func (*RootChoreoInstance) GetTempPath

func (r *RootChoreoInstance) GetTempPath() string

func (*RootChoreoInstance) GetUpstreamRef

func (r *RootChoreoInstance) GetUpstreamRef() *choreov1alpha1.UpstreamRef

func (*RootChoreoInstance) InitAPIs

func (r *RootChoreoInstance) InitAPIs()

func (*RootChoreoInstance) InitChildren

func (r *RootChoreoInstance) InitChildren()

func (*RootChoreoInstance) InitLibraries

func (r *RootChoreoInstance) InitLibraries()

func (*RootChoreoInstance) InitReconcilers

func (r *RootChoreoInstance) InitReconcilers()

func (*RootChoreoInstance) IsRootInstance

func (r *RootChoreoInstance) IsRootInstance() bool

func (*RootChoreoInstance) LoadInternalAPIs

func (r *RootChoreoInstance) LoadInternalAPIs() error

func (*RootChoreoInstance) PushBranch

func (r *RootChoreoInstance) PushBranch(branch string) (*choreopb.Push_Response, error)

func (*RootChoreoInstance) SchemaLoader

func (r *RootChoreoInstance) SchemaLoader() *schemaloader.SchemaLoader

func (*RootChoreoInstance) SchemaStore

func (r *RootChoreoInstance) SchemaStore() schemastore.Store

Jump to

Keyboard shortcuts

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