terraform

package
v0.6.2 Latest Latest
Warning

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

Go to latest
Published: Oct 10, 2023 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DiagnosticSeverityUnknown = "unknown"
	DiagnosticSeverityError   = "error"
	DiagnosticSeverityWarning = "warning"
)
View Source
const (

	// Parallelism is the number of resource to be work on in parallel during the apply/destroy commands.
	Parallelism = 8
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Diagnostic added in v0.4.2

type Diagnostic struct {
	Severity string `json:"severity"`
	Summary  string `json:"summary"`
	Detail   string `json:"detail"`
	Address  string `json:"address,omitempty"`
}

Taken from https://github.com/hashicorp/terraform/blob/2622e89cfb7eb62045fbb35956345eb4ad169704/internal/command/views/json/diagnostic.go#L34

type JSONLog added in v0.4.2

type JSONLog struct {
	Level      string      `json:"@level"`
	Message    string      `json:"@message"`
	Type       JSONLogType `json:"type"`
	Diagnostic *Diagnostic `json:"diagnostic"`
}

type JSONLogType added in v0.4.2

type JSONLogType string

Taken from https://github.com/hashicorp/terraform/blob/2622e89cfb7eb62045fbb35956345eb4ad169704/internal/command/jsonformat/renderer.go#L25

const (
	LogApplyComplete     JSONLogType = "apply_complete"
	LogApplyErrored      JSONLogType = "apply_errored"
	LogApplyStart        JSONLogType = "apply_start"
	LogChangeSummary     JSONLogType = "change_summary"
	LogDiagnostic        JSONLogType = "diagnostic"
	LogPlannedChange     JSONLogType = "planned_change"
	LogProvisionComplete JSONLogType = "provision_complete"
	LogProvisionErrored  JSONLogType = "provision_errored"
	LogProvisionProgress JSONLogType = "provision_progress"
	LogProvisionStart    JSONLogType = "provision_start"
	LogOutputs           JSONLogType = "outputs"
	LogRefreshComplete   JSONLogType = "refresh_complete"
	LogRefreshStart      JSONLogType = "refresh_start"
	LogResourceDrift     JSONLogType = "resource_drift"
	LogVersion           JSONLogType = "version"
)

type JSONLogs added in v0.4.2

type JSONLogs []JSONLog

type Terraform

type Terraform struct {
	// Directory represents the directory of .tf files
	Directory string

	Stdout io.Writer
	Stderr io.Writer

	// Parallelism is the number of resources to be worked on in parallel by terraform.
	Parallelism int

	// SpawnProcessLimit represents a synchronization channel which limits the number of spawned terraform
	// processes. This values must be non-nil and be buffered, where the capacity indicates
	// the limit.
	SpawnProcessLimit chan struct{}
}

func (*Terraform) Apply

func (t *Terraform) Apply() error

func (*Terraform) Destroy

func (t *Terraform) Destroy() error

func (*Terraform) Init

func (t *Terraform) Init() error

func (*Terraform) Output

func (t *Terraform) Output(resourceName string) (string, error)

Jump to

Keyboard shortcuts

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