drift

package
v1.15.18 Latest Latest
Warning

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

Go to latest
Published: Dec 9, 2023 License: Apache-2.0 Imports: 7 Imported by: 4

Documentation

Index

Constants

View Source
const (
	PriorityLowest  = Priority(100)
	PriorityLow     = Priority(200)
	PriorityNormal  = Priority(300)
	PriorityHigh    = Priority(400)
	PriorityHighest = Priority(500)
)
View Source
const (
	MagicTrackedString                = "THIS FILE IS AUTOGENERATED BY SYNCER" + " DO NOT EDIT"
	DefaultSyncerGeneratedGoDirectory = "internal"
	DefaultSyncerGeneratedGoFilename  = "syncer.go"
	DefaultSyncerConfigFileName       = ".syncer.yaml"
)
View Source
const (
	FxTagSyncers = `group:"syncers"`
)

Variables

Functions

This section is empty.

Types

type Detector

type Detector interface {
	DetectDrift(ctx context.Context, runData *RunData) (*files.System[*files.StateWithChangeReason], error)
	Name() config.Name
	Priority() Priority
}

type ErrSyncerAlreadyRegistered

type ErrSyncerAlreadyRegistered struct {
	Name string
}

func (*ErrSyncerAlreadyRegistered) Error

type Priority

type Priority int

func (Priority) String

func (p Priority) String() string

type Registry

type Registry interface {
	Registered() []Detector
	Get(name config.Name) (Detector, bool)
}

func NewRegistry

func NewRegistry(syncers []Detector) (Registry, error)

type RunData

type RunData struct {
	// The root config file
	RootConfig *config.Root
	// The subsection of the config file that is relevant to this run
	RunConfig config.Dynamic
	// The registries of this run
	Registry Registry
	// Where we want to copy destination files to
	DestinationWorkingDir string
}

func (*RunData) AutogenMsg

func (r *RunData) AutogenMsg() string

Directories

Path Synopsis
syncers

Jump to

Keyboard shortcuts

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