Documentation
¶
Index ¶
- Variables
- func Cmd(opts *CmdOptions, args ...string) ([]byte, error)
- func CreateConfigFile(dir string, terraformCloudHost string, terraformCloudToken string) (string, error)
- func GetUsageOnlyResources() []string
- func IsTerraformDir(path string) bool
- func NewDirProvider(ctx *settings.ProjectSession, includePastResources bool) engine.Vendor
- func NewPlanProvider(ctx *settings.ProjectSession, includePastResources bool) engine.Vendor
- func NewStateJSONProvider(ctx *settings.ProjectSession, includePastResources bool) engine.Vendor
- func NewTerragruntHCLProvider(rootPath hcl.RootPath, ctx *settings.ProjectSession) engine.Vendor
- func NewTerragruntProvider(ctx *settings.ProjectSession, includePastResources bool) engine.Vendor
- func ReadPlanCache(p *DirProvider) ([]byte, error)
- func StripSetupTerraformWrapper(b []byte) ([]byte, bool)
- func UsePlanCache(p *DirProvider) bool
- func WritePlanCache(p *DirProvider, planJSON []byte)
- type CmdError
- type CmdOptions
- type ConfLoader
- type Configuration
- type DirProvider
- func (p *DirProvider) AddMetadata(metadata *engine.WorkspaceMeta)
- func (p *DirProvider) Context() *settings.ProjectSession
- func (p *DirProvider) DisplayType() string
- func (p *DirProvider) LoadResources(usage engine.ConsumptionMap) ([]*engine.Workspace, error)
- func (p *DirProvider) ProjectName() string
- func (p *DirProvider) RelativePath() string
- func (p *DirProvider) Type() string
- func (p *DirProvider) VarFiles() []string
- type HCLLoader
- func (p *HCLLoader) AddMetadata(metadata *engine.WorkspaceMeta)
- func (p *HCLLoader) Context() *settings.ProjectSession
- func (p *HCLLoader) DependencyPaths() []string
- func (p *HCLLoader) DisplayType() string
- func (p *HCLLoader) EnvName() string
- func (p *HCLLoader) InvalidateCache() *HCLLoader
- func (p *HCLLoader) LoadPlanJSON() HCLProject
- func (p *HCLLoader) LoadResources(usage engine.ConsumptionMap) ([]*engine.Workspace, error)
- func (p *HCLLoader) Module() HCLProject
- func (p *HCLLoader) ProjectName() string
- func (p *HCLLoader) RelativePath() string
- func (p *HCLLoader) Type() string
- func (p *HCLLoader) VarFiles() []string
- func (p *HCLLoader) YAML() string
- type HCLProject
- type HCLProviderConfig
- type MalformedRegistryURLErr
- type ModuleCall
- type ModuleConfig
- type ModuleDownloadErr
- type ModuleOut
- type ParsedPlanConfiguration
- type Parser
- type PlanJSONProvider
- func (p *PlanJSONProvider) AddMetadata(metadata *engine.WorkspaceMeta)
- func (p *PlanJSONProvider) Context() *settings.ProjectSession
- func (p *PlanJSONProvider) DisplayType() string
- func (p *PlanJSONProvider) LoadResources(usage engine.ConsumptionMap) ([]*engine.Workspace, error)
- func (p *PlanJSONProvider) LoadResourcesFromSrc(usage engine.ConsumptionMap, j []byte) (*engine.Workspace, error)
- func (p *PlanJSONProvider) ProjectName() string
- func (p *PlanJSONProvider) RelativePath() string
- func (p *PlanJSONProvider) Type() string
- func (p *PlanJSONProvider) VarFiles() []string
- type PlanModule
- type PlanProvider
- func (p *PlanProvider) DisplayType() string
- func (p *PlanProvider) LoadResources(usage engine.ConsumptionMap) (projects []*engine.Workspace, err error)
- func (p *PlanProvider) ProjectName() string
- func (p *PlanProvider) RelativePath() string
- func (p *PlanProvider) Type() string
- func (p *PlanProvider) VarFiles() []string
- type PlanSchema
- type PlanValues
- type ProviderConfig
- type RegistryAPIErr
- type RegistryItemMap
- func (r *RegistryItemMap) GetCustomRefIDFunc(resourceDataType string) engine.ReferenceIDFunc
- func (r *RegistryItemMap) GetDefaultRefIDFunc(resourceDataType string) engine.ReferenceIDFunc
- func (r *RegistryItemMap) GetReferenceAttributes(resourceDataType string) []string
- func (r *RegistryItemMap) GetRegion(resourceDataType string) engine.RegionLookupFunc
- type ResourceChange
- type ResourceChangesJSON
- type ResourceData
- type ResourceJSON
- type ResourceOutput
- type RunShowOptions
- type ServiceDiscoveryErr
- type StateJSONProvider
- func (p *StateJSONProvider) AddMetadata(metadata *engine.WorkspaceMeta)
- func (p *StateJSONProvider) Context() *settings.ProjectSession
- func (p *StateJSONProvider) DisplayType() string
- func (p *StateJSONProvider) LoadResources(usage engine.ConsumptionMap) ([]*engine.Workspace, error)
- func (p *StateJSONProvider) ProjectName() string
- func (p *StateJSONProvider) RelativePath() string
- func (p *StateJSONProvider) Type() string
- func (p *StateJSONProvider) VarFiles() []string
- type TerraformRegistryGetter
- func (tfrGetter *TerraformRegistryGetter) ClientMode(ctx context.Context, u *url.URL) (getter.ClientMode, error)
- func (tfrGetter *TerraformRegistryGetter) Get(ctx context.Context, dstPath string, srcURL *url.URL) error
- func (tfrGetter *TerraformRegistryGetter) GetFile(dst string, src *url.URL) error
- func (tfrGetter *TerraformRegistryGetter) SetClient(client *getter.Client)
- type TerraformRegistryServicePath
- type TerragruntHCLProvider
- func (p *TerragruntHCLProvider) AddMetadata(metadata *engine.WorkspaceMeta)
- func (p *TerragruntHCLProvider) Context() *settings.ProjectSession
- func (p *TerragruntHCLProvider) DependencyPaths() []string
- func (p *TerragruntHCLProvider) DisplayType() string
- func (p *TerragruntHCLProvider) EnvName() string
- func (p *TerragruntHCLProvider) LoadResources(usage engine.ConsumptionMap) ([]*engine.Workspace, error)
- func (p *TerragruntHCLProvider) ProjectName() string
- func (p *TerragruntHCLProvider) RelativePath() string
- func (p *TerragruntHCLProvider) Type() string
- func (p *TerragruntHCLProvider) VarFiles() []string
- func (p *TerragruntHCLProvider) YAML() string
- type TerragruntInfo
- type TerragruntOutputCache
- type TerragruntProvider
- func (p *TerragruntProvider) AddMetadata(metadata *engine.WorkspaceMeta)
- func (p *TerragruntProvider) Context() *settings.ProjectSession
- func (p *TerragruntProvider) DisplayType() string
- func (p *TerragruntProvider) LoadResources(usage engine.ConsumptionMap) ([]*engine.Workspace, error)
- func (p *TerragruntProvider) ProjectName() string
- func (p *TerragruntProvider) RelativePath() string
- func (p *TerragruntProvider) Type() string
- func (p *TerragruntProvider) VarFiles() []string
- type YorConfig
Constants ¶
This section is empty.
Variables ¶
var (
ResourceRegistryMap = buildResourceRegistryMap()
)
Functions ¶
func CreateConfigFile ¶
func GetUsageOnlyResources ¶
func GetUsageOnlyResources() []string
func IsTerraformDir ¶
func NewDirProvider ¶
func NewDirProvider(ctx *settings.ProjectSession, includePastResources bool) engine.Vendor
func NewPlanProvider ¶
func NewPlanProvider(ctx *settings.ProjectSession, includePastResources bool) engine.Vendor
func NewStateJSONProvider ¶
func NewStateJSONProvider(ctx *settings.ProjectSession, includePastResources bool) engine.Vendor
func NewTerragruntHCLProvider ¶
NewTerragruntHCLProvider creates a new provider initialized with the configured project path (usually the terragrunt root directory).
func NewTerragruntProvider ¶
func NewTerragruntProvider(ctx *settings.ProjectSession, includePastResources bool) engine.Vendor
func ReadPlanCache ¶
func ReadPlanCache(p *DirProvider) ([]byte, error)
func StripSetupTerraformWrapper ¶
StripSetupTerraformWrapper removes any output added from the setup-terraform GitHub action terraform wrapper, so we can parse the output of this as valid JSON. It returns the stripped out JSON and a boolean that is true if the wrapper output was found and removed.
func UsePlanCache ¶
func UsePlanCache(p *DirProvider) bool
func WritePlanCache ¶
func WritePlanCache(p *DirProvider, planJSON []byte)
Types ¶
type CmdOptions ¶
type ConfLoader ¶
type ConfLoader struct {
// contains filtered or unexported fields
}
func NewConfLoader ¶
func NewConfLoader(conf gjson.Result) *ConfLoader
func (*ConfLoader) GetModuleConfJSON ¶
func (l *ConfLoader) GetModuleConfJSON(names []string) gjson.Result
func (*ConfLoader) GetResourceConfJSON ¶
func (l *ConfLoader) GetResourceConfJSON(addr string) gjson.Result
type Configuration ¶
type Configuration struct {
ProviderConfig map[string]ProviderConfig `json:"provider_config"`
RootModule ModuleConfig `json:"root_module"`
}
type DirProvider ¶
type DirProvider struct {
Path string
IsTerragrunt bool
PlanFlags string
InitFlags string
Workspace string
UseState bool
TerraformBinary string
TerraformCloudHost string
TerraformCloudToken string
Env map[string]string
// contains filtered or unexported fields
}
func (*DirProvider) AddMetadata ¶
func (p *DirProvider) AddMetadata(metadata *engine.WorkspaceMeta)
func (*DirProvider) Context ¶
func (p *DirProvider) Context() *settings.ProjectSession
func (*DirProvider) DisplayType ¶
func (p *DirProvider) DisplayType() string
func (*DirProvider) LoadResources ¶
func (p *DirProvider) LoadResources(usage engine.ConsumptionMap) ([]*engine.Workspace, error)
func (*DirProvider) ProjectName ¶
func (p *DirProvider) ProjectName() string
func (*DirProvider) RelativePath ¶
func (p *DirProvider) RelativePath() string
func (*DirProvider) Type ¶
func (p *DirProvider) Type() string
func (*DirProvider) VarFiles ¶
func (p *DirProvider) VarFiles() []string
type HCLLoader ¶
func NewHCLProvider ¶
func NewHCLProvider(ctx *settings.ProjectSession, rootPath hcl.RootPath, config *HCLProviderConfig, opts ...hcl.Option) (*HCLLoader, error)
NewHCLProvider returns a HCLProvider with a hcl.Parser initialised using the settings.ProjectSession. It will use input flags from either the terraform-plan-flags or top level var and var-file flags to set input vars and files on the underlying hcl.Parser.
func (*HCLLoader) AddMetadata ¶
func (p *HCLLoader) AddMetadata(metadata *engine.WorkspaceMeta)
func (*HCLLoader) Context ¶
func (p *HCLLoader) Context() *settings.ProjectSession
func (*HCLLoader) DependencyPaths ¶
func (*HCLLoader) DisplayType ¶
func (*HCLLoader) InvalidateCache ¶
InvalidateCache removes the module cache from the prior hcl parse.
func (*HCLLoader) LoadPlanJSON ¶
func (p *HCLLoader) LoadPlanJSON() HCLProject
LoadPlanJSON parses the RootPath and return the blocks in Terraform plan JSON format.
func (*HCLLoader) LoadResources ¶
LoadResources calls a hcl.Parser to parse the directory config files into hcl.Blocks. It then builds a shallow representation of the terraform plan JSON files from these Blocks, this is passed to the PlanJSONProvider. The PlanJSONProvider uses this shallow representation to actually load C3X resources.
func (*HCLLoader) Module ¶
func (p *HCLLoader) Module() HCLProject
Module parses the RootPath into an hcl Module representing a config tree of Terraform information. Module returns the raw hcl blocks associated with each found Terraform project. This can be used to fetch raw information like outputs, vars, resources, e.t.c.
func (*HCLLoader) ProjectName ¶
func (*HCLLoader) RelativePath ¶
type HCLProviderConfig ¶
type MalformedRegistryURLErr ¶
type MalformedRegistryURLErr struct {
// contains filtered or unexported fields
}
MalformedRegistryURLErr is returned if the Terraform Registry URL passed to the Getter is malformed.
func (MalformedRegistryURLErr) Error ¶
func (err MalformedRegistryURLErr) Error() string
type ModuleCall ¶
type ModuleCall struct {
Source string `json:"source"`
ModuleConfig ModuleConfig `json:"module"`
SourceUrl string `json:"sourceUrl,omitempty"`
}
type ModuleConfig ¶
type ModuleConfig struct {
Resources []ResourceData `json:"resources,omitempty"`
ModuleCalls map[string]ModuleCall `json:"module_calls,omitempty"`
}
type ModuleDownloadErr ¶
type ModuleDownloadErr struct {
// contains filtered or unexported fields
}
ModuleDownloadErr is returned if Terragrunt failed to download the module.
func (ModuleDownloadErr) Error ¶
func (err ModuleDownloadErr) Error() string
type ModuleOut ¶
type ModuleOut struct {
PlanModule PlanModule
ModuleConfig ModuleConfig
}
type ParsedPlanConfiguration ¶
type ParsedPlanConfiguration struct {
PastResources []*engine.UnpricedEntry
PastResourceDatas []*engine.ResourceSpec
CurrentResources []*engine.UnpricedEntry
CurrentResourceDatas []*engine.ResourceSpec
ProviderMetadata []engine.VendorMeta
RemoteModuleCalls []string
}
type PlanJSONProvider ¶
type PlanJSONProvider struct {
Path string
// contains filtered or unexported fields
}
func NewPlanJSONProvider ¶
func NewPlanJSONProvider(ctx *settings.ProjectSession, includePastResources bool) *PlanJSONProvider
func (*PlanJSONProvider) AddMetadata ¶
func (p *PlanJSONProvider) AddMetadata(metadata *engine.WorkspaceMeta)
func (*PlanJSONProvider) Context ¶
func (p *PlanJSONProvider) Context() *settings.ProjectSession
func (*PlanJSONProvider) DisplayType ¶
func (p *PlanJSONProvider) DisplayType() string
func (*PlanJSONProvider) LoadResources ¶
func (p *PlanJSONProvider) LoadResources(usage engine.ConsumptionMap) ([]*engine.Workspace, error)
func (*PlanJSONProvider) LoadResourcesFromSrc ¶
func (p *PlanJSONProvider) LoadResourcesFromSrc(usage engine.ConsumptionMap, j []byte) (*engine.Workspace, error)
func (*PlanJSONProvider) ProjectName ¶
func (p *PlanJSONProvider) ProjectName() string
func (*PlanJSONProvider) RelativePath ¶
func (p *PlanJSONProvider) RelativePath() string
func (*PlanJSONProvider) Type ¶
func (p *PlanJSONProvider) Type() string
func (*PlanJSONProvider) VarFiles ¶
func (p *PlanJSONProvider) VarFiles() []string
type PlanModule ¶
type PlanModule struct {
Resources []ResourceJSON `json:"resources,omitempty"`
Address *string `json:"address,omitempty"`
ChildModules []PlanModule `json:"child_modules,omitempty"`
}
type PlanProvider ¶
type PlanProvider struct {
*DirProvider
Path string
// contains filtered or unexported fields
}
func (*PlanProvider) DisplayType ¶
func (p *PlanProvider) DisplayType() string
func (*PlanProvider) LoadResources ¶
func (p *PlanProvider) LoadResources(usage engine.ConsumptionMap) (projects []*engine.Workspace, err error)
func (*PlanProvider) ProjectName ¶
func (p *PlanProvider) ProjectName() string
func (*PlanProvider) RelativePath ¶
func (p *PlanProvider) RelativePath() string
func (*PlanProvider) Type ¶
func (p *PlanProvider) Type() string
func (*PlanProvider) VarFiles ¶
func (p *PlanProvider) VarFiles() []string
type PlanSchema ¶
type PlanSchema struct {
FormatVersion string `json:"format_version"`
TerraformVersion string `json:"terraform_version"`
Variables interface{} `json:"variables,omitempty"`
PriorState struct {
Values PlanValues `json:"values"`
} `json:"prior_state"`
PlannedValues PlanValues `json:"planned_values"`
Configuration Configuration `json:"configuration"`
// C3XResourceChanges is a flattened list of resource changes for the plan, this is in the format of the Terraform
// plan JSON output, but we omit adding it as the supported `resource_changes` key as this will cause plan inconsistencies.
// We copy this `c3x_resource_changes` key at a later date to `resource_changes` before sending to the Policy API.
// This means that we can evaluate the Rego ruleset on the known Terraform plan JSON structure.
C3XResourceChanges []ResourceChangesJSON `json:"c3x_resource_changes"`
C3XProviderConstraints hcl.ProviderConstraints `json:"c3x_provider_constraints"`
}
type PlanValues ¶
type PlanValues struct {
RootModule PlanModule `json:"root_module"`
}
type ProviderConfig ¶
type RegistryAPIErr ¶
type RegistryAPIErr struct {
// contains filtered or unexported fields
}
RegistryAPIErr is returned if we get an unsuccessful HTTP return code from the registry.
func (RegistryAPIErr) Error ¶
func (err RegistryAPIErr) Error() string
type RegistryItemMap ¶
type RegistryItemMap map[string]*engine.CatalogEntry
func (*RegistryItemMap) GetCustomRefIDFunc ¶
func (r *RegistryItemMap) GetCustomRefIDFunc(resourceDataType string) engine.ReferenceIDFunc
func (*RegistryItemMap) GetDefaultRefIDFunc ¶
func (r *RegistryItemMap) GetDefaultRefIDFunc(resourceDataType string) engine.ReferenceIDFunc
func (*RegistryItemMap) GetReferenceAttributes ¶
func (r *RegistryItemMap) GetReferenceAttributes(resourceDataType string) []string
func (*RegistryItemMap) GetRegion ¶
func (r *RegistryItemMap) GetRegion(resourceDataType string) engine.RegionLookupFunc
GetRegion returns the region lookup function for the given resource data type if it exists.
type ResourceChange ¶
type ResourceChangesJSON ¶
type ResourceData ¶
type ResourceData struct {
Address string `json:"address"`
Mode string `json:"mode"`
Type string `json:"type"`
Name string `json:"name"`
ProviderConfigKey string `json:"provider_config_key"`
Expressions map[string]interface{} `json:"expressions,omitempty"`
SchemaVersion int `json:"schema_version"`
CountExpression *countExpression `json:"count_expression,omitempty"`
}
type ResourceJSON ¶
type ResourceJSON struct {
Address string `json:"address"`
Mode string `json:"mode"`
Type string `json:"type"`
Name string `json:"name"`
Index *int64 `json:"index,omitempty"`
SchemaVersion int `json:"schema_version"`
Values map[string]interface{} `json:"values"`
C3XMetadata map[string]interface{} `json:"c3x_metadata"`
}
type ResourceOutput ¶
type ResourceOutput struct {
Planned ResourceJSON
Changes ResourceChangesJSON
PriorState ResourceJSON
Configuration ResourceData
}
type RunShowOptions ¶
type RunShowOptions struct {
CmdOptions *CmdOptions
}
type ServiceDiscoveryErr ¶
type ServiceDiscoveryErr struct {
// contains filtered or unexported fields
}
ServiceDiscoveryErr is returned if Terragrunt failed to identify the module API endpoint through the service discovery protocol.
func (ServiceDiscoveryErr) Error ¶
func (err ServiceDiscoveryErr) Error() string
type StateJSONProvider ¶
type StateJSONProvider struct {
Path string
// contains filtered or unexported fields
}
func (*StateJSONProvider) AddMetadata ¶
func (p *StateJSONProvider) AddMetadata(metadata *engine.WorkspaceMeta)
func (*StateJSONProvider) Context ¶
func (p *StateJSONProvider) Context() *settings.ProjectSession
func (*StateJSONProvider) DisplayType ¶
func (p *StateJSONProvider) DisplayType() string
func (*StateJSONProvider) LoadResources ¶
func (p *StateJSONProvider) LoadResources(usage engine.ConsumptionMap) ([]*engine.Workspace, error)
func (*StateJSONProvider) ProjectName ¶
func (p *StateJSONProvider) ProjectName() string
func (*StateJSONProvider) RelativePath ¶
func (p *StateJSONProvider) RelativePath() string
func (*StateJSONProvider) Type ¶
func (p *StateJSONProvider) Type() string
func (*StateJSONProvider) VarFiles ¶
func (p *StateJSONProvider) VarFiles() []string
type TerraformRegistryGetter ¶
type TerraformRegistryGetter struct {
// contains filtered or unexported fields
}
TerraformRegistryGetter is a Getter (from modsource) implementation that will download from the terraform module registry. This supports getter URLs encoded in the following manner:
tfr://REGISTRY_DOMAIN/MODULE_PATH?version=VERSION
Where the REGISTRY_DOMAIN is the terraform registry endpoint (e.g., registry.terraform.io), MODULE_PATH is the registry path for the module (e.g., terraform-aws-modules/vpc/aws), and VERSION is the specific version of the module to download (e.g., 2.2.0).
This protocol will use the Module Registry Protocol (documented at https://www.terraform.io/docs/internals/module-registry-protocol.html) to lookup the module source URL and download it.
Authentication to private module registries is handled via environment variables. The authorization API token is expected to be provided to Terragrunt via the TG_TF_REGISTRY_TOKEN environment variable. This token can be any registry API token generated on Terraform Cloud / Enterprise.
MAINTAINER'S NOTE: Ideally we implement the full credential system that terraform uses as part of `terraform login`, but all the relevant packages are internal to the terraform repository, thus making it difficult to use as a library. For now, we keep things simple by supporting providing tokens via env vars and in the future, we can consider implementing functionality to load credentials from terraform. See: https://github.com/c3xdev/c3x/issues/1771
MAINTAINER'S NOTE: Ideally we can support a shorthand notation that omits the tfr:// protocol to detect that it is referring to a terraform registry, but this requires implementing a complex detector and ensuring it has precedence over the file detector. We deferred the implementation for that to a future release. See: https://github.com/c3xdev/c3x/issues/1772
func (*TerraformRegistryGetter) ClientMode ¶
func (tfrGetter *TerraformRegistryGetter) ClientMode(ctx context.Context, u *url.URL) (getter.ClientMode, error)
ClientMode returns the download mode based on the given URL. Since this getter is designed around the Terraform module registry, we always use Dir mode so that we can download the full Terraform module.
func (*TerraformRegistryGetter) Get ¶
func (tfrGetter *TerraformRegistryGetter) Get(ctx context.Context, dstPath string, srcURL *url.URL) error
Get is the main routine to fetch the module contents specified at the given URL and download it to the dstPath. This routine assumes that the srcURL points to the Terraform registry URL, with the Path configured to the module path encoded as `:namespace/:name/:system` as expected by the Terraform registry. Note that the URL query parameter must have the `version` key to specify what version to download.
func (*TerraformRegistryGetter) GetFile ¶
func (tfrGetter *TerraformRegistryGetter) GetFile(dst string, src *url.URL) error
GetFile is not implemented for the Terraform module registry Getter since the terraform module registry doesn't serve a single file.
func (*TerraformRegistryGetter) SetClient ¶
func (tfrGetter *TerraformRegistryGetter) SetClient(client *getter.Client)
SetClient allows the getter to know what getter client (different from the underlying HTTP client) to use for progress tracking.
type TerraformRegistryServicePath ¶
type TerraformRegistryServicePath struct {
ModulesPath string `json:"modules.v1"`
}
TerraformRegistryServicePath is a struct for extracting the modules service path in the Registry.
type TerragruntHCLProvider ¶
func (*TerragruntHCLProvider) AddMetadata ¶
func (p *TerragruntHCLProvider) AddMetadata(metadata *engine.WorkspaceMeta)
func (*TerragruntHCLProvider) Context ¶
func (p *TerragruntHCLProvider) Context() *settings.ProjectSession
func (*TerragruntHCLProvider) DependencyPaths ¶
func (p *TerragruntHCLProvider) DependencyPaths() []string
func (*TerragruntHCLProvider) DisplayType ¶
func (p *TerragruntHCLProvider) DisplayType() string
func (*TerragruntHCLProvider) EnvName ¶
func (p *TerragruntHCLProvider) EnvName() string
func (*TerragruntHCLProvider) LoadResources ¶
func (p *TerragruntHCLProvider) LoadResources(usage engine.ConsumptionMap) ([]*engine.Workspace, error)
LoadResources finds any Terragrunt projects, prepares them by downloading any required source files, then process each with an HCLProvider.
func (*TerragruntHCLProvider) ProjectName ¶
func (p *TerragruntHCLProvider) ProjectName() string
func (*TerragruntHCLProvider) RelativePath ¶
func (p *TerragruntHCLProvider) RelativePath() string
func (*TerragruntHCLProvider) Type ¶
func (p *TerragruntHCLProvider) Type() string
func (*TerragruntHCLProvider) VarFiles ¶
func (p *TerragruntHCLProvider) VarFiles() []string
func (*TerragruntHCLProvider) YAML ¶
func (p *TerragruntHCLProvider) YAML() string
type TerragruntInfo ¶
type TerragruntOutputCache ¶
type TerragruntOutputCache struct {
// contains filtered or unexported fields
}
func (*TerragruntOutputCache) Set ¶
func (o *TerragruntOutputCache) Set(key string, getVal func() (cty.Value, error)) (cty.Value, error)
Set stores a value in the cache for the given key using the value returned from getVal function. If the key already exists in the cache, the value is returned from the cache.
type TerragruntProvider ¶
type TerragruntProvider struct {
Path string
TerragruntFlags string
*DirProvider
// contains filtered or unexported fields
}
func (*TerragruntProvider) AddMetadata ¶
func (p *TerragruntProvider) AddMetadata(metadata *engine.WorkspaceMeta)
func (*TerragruntProvider) Context ¶
func (p *TerragruntProvider) Context() *settings.ProjectSession
func (*TerragruntProvider) DisplayType ¶
func (p *TerragruntProvider) DisplayType() string
func (*TerragruntProvider) LoadResources ¶
func (p *TerragruntProvider) LoadResources(usage engine.ConsumptionMap) ([]*engine.Workspace, error)
func (*TerragruntProvider) ProjectName ¶
func (p *TerragruntProvider) ProjectName() string
func (*TerragruntProvider) RelativePath ¶
func (p *TerragruntProvider) RelativePath() string
func (*TerragruntProvider) Type ¶
func (p *TerragruntProvider) Type() string
func (*TerragruntProvider) VarFiles ¶
func (p *TerragruntProvider) VarFiles() []string
type YorConfig ¶
type YorConfig struct {
Name string `yaml:"name"`
Value struct {
Default string `yaml:"default"`
} `yaml:"value"`
TagGroups []struct {
Name string `yaml:"name"`
Tags []struct {
Name string `yaml:"name"`
Value struct {
Default string `yaml:"default"`
} `yaml:"value"`
} `yaml:"tags"`
} `yaml:"tag_groups"`
}