engine

package
v0.66.9 Latest Latest
Warning

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

Go to latest
Published: Aug 20, 2024 License: MIT Imports: 29 Imported by: 0

Documentation

Index

Constants

View Source
const (
	EnableExperimentalEngineEnvName                  = "TG_EXPERIMENTAL_ENGINE"
	DefaultCacheDir                                  = ".cache"
	EngineCacheDir                                   = "terragrunt/plugins/iac-engine"
	PrefixTrim                                       = "terragrunt-"
	FileNameFormat                                   = "terragrunt-iac-%s_%s_%s_%s_%s"
	ChecksumFileNameFormat                           = "terragrunt-iac-%s_%s_%s_SHA256SUMS"
	EngineCachePathEnv                               = "TG_ENGINE_CACHE_PATH"
	EngineSkipCheckEnv                               = "TG_ENGINE_SKIP_CHECK"
	TerraformCommandContextKey      engineClientsKey = iota
	LocksContextKey                 engineLocksKey   = iota
)
View Source
const PublicKey = `` /* 2431-byte string literal not displayed */

Variables

This section is empty.

Functions

func ConvertMetaToProtobuf added in v0.66.7

func ConvertMetaToProtobuf(meta map[string]interface{}) (map[string]*anypb.Any, error)

convert metadata map to protobuf map

func DownloadEngine added in v0.63.5

func DownloadEngine(ctx context.Context, opts *options.TerragruntOptions) error

DownloadEngine downloads the engine for the given options.

func IsEngineEnabled

func IsEngineEnabled() bool

IsEngineEnabled returns true if the experimental engine is enabled.

func ReadEngineOutput added in v0.66.7

func ReadEngineOutput(runOptions *ExecutionOptions, output outputFn) error

ReadEngineOutput reads the output from the engine, since grpc plugins don't have common type, use lambda function to read bytes from the stream

func Run

func Run(
	ctx context.Context,
	runOptions *ExecutionOptions,
) (*util.CmdOutput, error)

Run executes the given command with the experimental engine.

func Shutdown

func Shutdown(ctx context.Context) error

Shutdown shuts down the experimental engine.

func WithEngineValues added in v0.66.3

func WithEngineValues(ctx context.Context) context.Context

WithEngineValues add to context default values for engine.

Types

type ExecutionOptions

type ExecutionOptions struct {
	TerragruntOptions *options.TerragruntOptions
	CmdStdout         io.Writer
	CmdStderr         io.Writer
	WorkingDir        string
	SuppressStdout    bool
	AllocatePseudoTty bool
	Command           string
	Args              []string
}

type OutputLine added in v0.66.7

type OutputLine struct {
	Stdout string
	Stderr string
}

common engine output

Jump to

Keyboard shortcuts

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