tfconfig

package
v0.2.3 Latest Latest
Warning

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

Go to latest
Published: Jan 27, 2023 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Backend

type Backend struct {
	Type       string
	Attributes map[string]string

	Range hcl.Range
}

type Issue added in v0.2.0

type Issue struct {
	Severity   Severity
	Message    string
	ModulePath string
	Range      *hcl.Range
}

type Issues added in v0.2.0

type Issues []*Issue

Issues is an alias for the map of Issue

func ModuleShouldHaveLocalBackendOverride added in v0.2.0

func ModuleShouldHaveLocalBackendOverride(modules []*Module) Issues

func ModuleShouldHaveRemoteBackend added in v0.2.0

func ModuleShouldHaveRemoteBackend(modules []*Module) Issues

func ModuleShouldHaveUniqueBackend added in v0.2.0

func ModuleShouldHaveUniqueBackend(modules []*Module) Issues

func ParseRules added in v0.2.0

func ParseRules(modules []*Module, rules []func([]*Module) Issues) (issues Issues)

type Module

type Module struct {
	// Path is the local filesystem directory where the module was loaded from.
	Path string `json:"path"`

	RequiredCore []string `json:"required_core,omitempty"`
	Backends     []*Backend
}

Module is the top-level type representing a parsed and processed Terraform module.

func LoadModules

func LoadModules(workingDirs []string) (modules []*Module, diags hcl.Diagnostics)

type ModuleBackend added in v0.2.0

type ModuleBackend struct {
	ModulePath string
	Backend    *Backend
}

type Severity added in v0.2.0

type Severity int32
const (
	// ERROR is possible errors
	ERROR Severity = iota
	// WARNING doesn't cause problem immediately, but not good
	WARNING
	// NOTICE is not important, it's mentioned
	NOTICE
)

func (Severity) String added in v0.2.0

func (s Severity) String() string

String returns the string representation of the severity.

Jump to

Keyboard shortcuts

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