tool · inferred from evidence
tofu init
A command used to initialize OpenTofu, specifically for setting up provider plugins.
- Error: Failed to install provider
Fixes OpenTofu's 'Error: Failed to install provider' when the registry demands auth or the download fails. Use when tofu init fails installing a specific provider version with a registry or network complaint. Not for 'Failed to query availa
- Error: Inconsistent dependency lock file
Fixes OpenTofu's 'Error: Inconsistent dependency lock file' by re-resolving provider versions with tofu init -upgrade. Use when tofu init, plan, or apply refuses because .terraform.lock.hcl doesn't match the providers in your configuration.
- Error: Failed to query available provider packages
Fixes OpenTofu's 'Error: Failed to query available provider packages' during tofu init, most often caused by a misspelled resource type prefix that makes tofu request a nonexistent provider. Use when init names a provider you never declared