package
1.0.1
Repository: https://github.com/terramate-io/opentofulib.git
Documentation: pkg.go.dev

# Packages

No description provided by the author
Package cliconfig has the types representing and the logic to load CLI-level configuration settings.
Package state exposes common helpers for working with state from the CLI.
Package e2etest contains a set of tests that run against a real OpenTofu binary, compiled on the fly at the start of the test run.
Package format contains helpers for formatting various OpenTofu structures for human-readabout output.
Package jsonchecks implements the common JSON representation of check results/statuses that we use across both the JSON plan and JSON state representations.
Package jsonconfig implements methods for outputting a configuration snapshot in machine-readable json format.
No description provided by the author
No description provided by the author
Package jsonplan implements methods for outputting a plan in a machine-readable json format.
Package jsonprovider contains types and functions to marshal OpenTofu provider schemas into a json formatted output.
Package jsonstate implements methods for outputting a state in a machine-readable json format.
No description provided by the author
No description provided by the author
No description provided by the author
Package workdir models the various local artifacts and state we keep inside a OpenTofu "working directory".

# Constants

DefaultBackupExtension is added to the state file to form the path.
DefaultCloudPluginVersion is the implied protocol version, though all historical versions are defined explicitly.
DefaultDataDir is the default directory for storing local data.
DefaultParallelism is the limit Terraform places on total parallel operations as it walks the dependency graph.
DefaultPluginVendorDir is the location in the config directory to look for user-added plugin binaries.
DefaultStateFilename is the default filename used for the state file.
DefaultVarsExtension is the default file extension used for vars.
DefaultVarsFilename is the default filename used for vars.
ErrUnsupportedLocalOp is the common error message shown for operations that require a backend.Local.
ExitRPCError is the exit code that is returned if an plugin communication error occurred.
InputModeEnvVar is the environment variable that, if set to "false" or "0", causes tofu commands to behave as if the `-input=false` flag was specified.
No description provided by the author
PluginPathFile is the name of the file in the data dir which stores the list of directories supplied by the user with the `-plugin-dir` flag during init.
VarEnvPrefix is the prefix for environment variables that represent values for root module input variables.
WorkspaceNameEnvVar is the name of the environment variable that can be used to set the name of the OpenTofu workspace, overriding the workspace chosen by `tofu workspace select`.

# Variables

Handshake is used to verify that the plugin is the appropriate plugin for the client.

# Structs

AliasCommand is a Command implementation that wraps another Command for the purpose of aliasing.
ApplyCommand is a Command implementation that applies a OpenTofu configuration and actually builds or changes infrastructure.
BackendOpts are the options used to initialize a backend.Backend.
CloudCommand is a Command implementation that interacts with Terraform Cloud for operations that are inherently planless.
ColorizeUi is a Ui implementation that colors its output according to the given color schemes for the given type of output.
ConsoleCommand is a Command implementation that starts an interactive console that can be used to try expressions with the current config.
FmtCommand is a Command implementation that rewrites OpenTofu config files to a canonical format and style.
GetCommand is a Command implementation that takes a OpenTofu configuration and downloads all the modules.
GraphCommand is a Command implementation that takes a OpenTofu configuration and outputs the dependency tree in graphical form.
ImportCommand is a cli.Command implementation that imports resources into the OpenTofu state.
InitCommand is a Command implementation that takes a Terraform module and clones it to the working directory.
LoginCommand is a Command implementation that runs an interactive login flow for a remote service host.
LogoutCommand is a Command implementation which removes stored credentials for a remote service host.
Meta are the meta-options that are available on all or most commands.
MetadataCommand is a Command implementation that just shows help for the subcommands nested below it.
MetadataFunctionsCommand is a Command implementation that prints out information about the available functions in OpenTofu.
OutputCommand is a Command implementation that reads an output from a OpenTofu state and prints it.
PlanCommand is a Command implementation that compares a OpenTofu configuration to an actual infrastructure and shows the differences.
ProvidersCommand is a Command implementation that prints out information about the providers used in the current configuration/state.
ProvidersLockCommand is a Command implementation that implements the "tofu providers lock" command, which creates or updates the current configuration's dependency lock file using information from upstream registries, regardless of the provider installation configuration that is configured for normal provider installation.
ProvidersMirrorCommand is a Command implementation that implements the "tofu providers mirror" command, which populates a directory with local copies of provider plugins needed by the current configuration so that the mirror can be used to work offline, or similar.
ProvidersSchemaCommand is a Command implementation that prints out information about the providers used in the current configuration/state.
No description provided by the author
RefreshCommand is a cli.Command implementation that refreshes the state file.
ShowCommand is a Command implementation that reads and outputs the contents of a OpenTofu plan or state file.
StateCommand is a Command implementation that just shows help for the subcommands nested below it.
StateListCommand is a Command implementation that lists the resources within a state file.
StateMeta is the meta struct that should be embedded in state subcommands.
StateMvCommand is a Command implementation that shows a single resource.
StatePullCommand is a Command implementation that shows a single resource.
StatePushCommand is a Command implementation that shows a single resource.
No description provided by the author
StateRmCommand is a Command implementation that shows a single resource.
StateShowCommand is a Command implementation that shows a single resource.
TaintCommand is a cli.Command implementation that manually taints a resource, marking it for recreation.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
UIInput is an implementation of tofu.UIInput that asks the CLI for input stdin.
UnlockCommand is a cli.Command implementation that manually unlocks the state.
UntaintCommand is a cli.Command implementation that manually untaints a resource, marking it as primary and ready for service.
ValidateCommand is a Command implementation that validates the tofu files.
VersionCommand is a Command implementation prints the version.
No description provided by the author
WorkspaceCommand is a Command Implementation that manipulates workspaces, which allow multiple distinct states and variables from a single config.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
WrappedUi is a shim which adds json compatibility to those commands which have not yet been refactored to support output by views.View.

# Interfaces

BackendWithRemoteTerraformVersion is a shared interface between the 'remote' and 'cloud' backends for simplified type checking when calling functions common to those particular backends.

# Type aliases

FlagStringKV is a flag.Value implementation for parsing user variables from the command-line in the format of '-var key=value', where value is only ever a primitive.
FlagStringSlice is a flag.Value implementation for parsing targets from the command line, e.g.