cli: Restore -lock and -lock-timeout init flags

The -lock and -lock-timeout flags were removed prior to the release of
1.0 as they were thought to have no effect. This is not true in the case
of state migrations when changing backends. This commit restores these
flags, and adds test coverage for locking during backend state
migration.

Also update the help output describing other boolean flags, showing the
argument as the user would type it rather than the default behavior.
This commit is contained in:
Alisdair McDiarmid
2021-10-18 14:41:04 -04:00
parent 7d3074df46
commit c587384dff
5 changed files with 102 additions and 7 deletions

View File

@@ -0,0 +1,5 @@
terraform {
backend "local" {
path = "local-state.tfstate"
}
}