config

package
v1.0.13 Latest Latest
Warning

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

Go to latest
Published: Feb 13, 2024 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const (
	TenvName       = "tenv"
	TerraformName  = "terraform"
	TerragruntName = "terragrunt"
	TofuName       = "tofu"

	TfRemoteURLEnvName = tfenvPrefix + remoteURLEnvName

	TfVersionEnvName = tfenvPrefix + "TERRAFORM_VERSION"

	TgRemoteURLEnvName = tgPrefix + remoteURLEnvName
	TgVersionEnvName   = tgPrefix + "VERSION"

	TofuRemoteURLEnvName = tofuenvPrefix + remoteURLEnvName

	TofuVersionEnvName = tofuenvPrefix + "TOFU_VERSION"
)

Variables

This section is empty.

Functions

func MapGetDefault added in v1.0.8

func MapGetDefault(m map[string]string, key string, defaultValue string) string

Types

type Config

type Config struct {
	AppLogger      hclog.Logger
	DisplayNormal  bool
	DisplayVerbose bool
	ForceQuiet     bool
	ForceRemote    bool
	GithubToken    string
	NoInstall      bool

	RemoteConfPath string
	RootPath       string
	Tf             RemoteConfig
	TfKeyPath      string
	Tg             RemoteConfig
	Tofu           RemoteConfig
	TofuKeyPath    string
	UserPath       string
	// contains filtered or unexported fields
}

func InitConfigFromEnv

func InitConfigFromEnv() (Config, error)

func (*Config) InitRemoteConf added in v1.0.8

func (conf *Config) InitRemoteConf() error

func (*Config) LogLevelUpdate added in v1.0.10

func (conf *Config) LogLevelUpdate()

type RemoteConfig added in v1.0.8

type RemoteConfig struct {
	Data map[string]string // values from conf file

	RemoteURL    string // value from flag
	RemoteURLEnv string // value from env
	// contains filtered or unexported fields
}

func (RemoteConfig) GetInstallMode added in v1.0.8

func (r RemoteConfig) GetInstallMode() string

func (RemoteConfig) GetListMode added in v1.0.8

func (r RemoteConfig) GetListMode() string

func (RemoteConfig) GetListURL added in v1.0.8

func (r RemoteConfig) GetListURL() string

func (RemoteConfig) GetRemoteURL added in v1.0.8

func (r RemoteConfig) GetRemoteURL() string

func (RemoteConfig) GetRewriteRule added in v1.0.8

func (r RemoteConfig) GetRewriteRule() []string

Jump to

Keyboard shortcuts

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