Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add terraform version command #1016

Merged
merged 9 commits into from
Aug 2, 2022
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 22 additions & 0 deletions docs/commands.md
Original file line number Diff line number Diff line change
Expand Up @@ -183,3 +183,25 @@ installed version.
}
}
```

### `module.terraform`

Provides information about the terraform binary version for the current module.

**Arguments:**

- `uri` - URI of the directory of the module in question, e.g. `file:///path/to/network`

**Outputs:**

- `v` - describes version of the format; Will be used in the future to communicate format changes.
- `required_version` - Version constraint specified in configuration
- `discovered_version` - Version discovered from `terraform version --json` using the `uri` given

```json
{
"v": 0,
"required_version": "~> 0.15",
"discovered_version": "1.1.0"
}
```