Commit Graph

30034 Commits

Author SHA1 Message Date
Alisdair McDiarmid
0c435e2e08 communicator/ssh: Fix crash using SSH+HTTP proxy 2022-05-03 08:24:59 -04:00
James Bardin
80792312d8
Merge pull request #30979 from hashicorp/jbardin/cancel-auto-approve
check for cancellation before apply confirmation
2022-05-02 17:14:14 -04:00
Alisdair McDiarmid
28e94013b6
Merge pull request #30975 from hashicorp/lockfile-mention-state
Add note about lockfile's relationship to state
2022-05-02 16:53:42 -04:00
Luces Huayhuaca
ea1f0007ff
fix typo for task.Status (#30978) 2022-05-02 11:52:22 -07:00
James Bardin
df0a70bfb6 check for cancellation before apply confirmation
When executing an apply with no plan, it's possible for a cancellation
to arrive during the final batch of provider operations, resulting in no
errors in the plan. The run context was next checked during the
confirmation for apply, but in the case of -auto-approve that
confirmation is skipped, resulting in the canceled plan being applied.

Make sure we directly check for cancellation before confirming the plan.
2022-05-02 14:09:47 -04:00
Dan Slimmon
1f6d986595 Include something about how state is checked 2022-05-02 09:57:25 +00:00
Laura Pacilio
3eea9d709d Add warning about spaces in variable value assignment 2022-04-29 16:59:39 -04:00
Kevin Wang
488853be9c
fix: img/docs/concrete-plan.png (#30967) 2022-04-29 15:33:45 -04:00
Laura Pacilio
78f90a64b5
Merge pull request #30956 from tigerblue77/patch-1
Update apt.mdx
2022-04-29 11:58:17 -04:00
James Bardin
f19848babf
Merge pull request #30962 from hashicorp/jbardin/update-ssh
udpate x/crypto/ssh
2022-04-28 16:44:23 -04:00
James Bardin
8699b115a7 udpate x/crypto/ssh 2022-04-28 16:21:09 -04:00
James Bardin
0bcd04a561
Merge pull request #30958 from hashicorp/jbardin/dependencies-race
Fix race in state dependency encoding
2022-04-28 11:56:51 -04:00
James Bardin
2bd72914d8 add internal/states to the race detector tests
This runs relatively quickly, and there is at least 1 test with
concurrent operations.
2022-04-28 11:44:32 -04:00
James Bardin
34a01c92d6 copy Dependencies before sorting in state
Instances of the same AbsResource may share the same Dependencies, which
could point to the same backing array of values. Since address values
are not pointers, and not meant to be shared, we must copy the value
before sorting the slice in-place. Because individual instances of the
same resource may be encoded to state concurrently, failure to copy the
slice first can result in a data race.
2022-04-28 11:44:32 -04:00
Tigerblue77
2928967b41
Update apt.mdx
- Removed usage of `apt-key` which is deprecated and replaced by `gpg` command
- Removed usage of `curl` command which is not present by default on Debian systems
2022-04-28 14:58:56 +02:00
Martin Atkins
7e37d486dd
Update CHANGELOG.md 2022-04-27 17:15:21 -07:00
htamakos
4cfb6bc893
communicator/ssh: Add support SSH over HTTP Proxy (#30274)
Terraform's remote-exec provision hangs out when it execs on HTTP Proxy bacause it dosen't support SSH over HTTP Proxy. This commits enables Terraform's remote-exec to support SSH over HTTP Proxy.

* adds `proxy_*` fields to `connection` which add configuration for a proxy host
* if `proxy_host` set, connect to that proxy host via CONNECT method, then make the SSH connection to `host` or `bastion_host`
2022-04-27 16:59:17 -04:00
James Bardin
de65cc43f3 update version to 1.3.0 2022-04-27 15:52:08 -04:00
Alisdair McDiarmid
5e023ecfee
Merge pull request #30949 from hashicorp/alisdair/typeexpr-tests
typeexpr: Add test coverage
2022-04-27 15:44:00 -04:00
James Bardin
cc8e6fa05a update go version 2022-04-27 15:04:30 -04:00
James Bardin
207e568010 v1.3 changelog 2022-04-27 14:56:26 -04:00
Alisdair McDiarmid
c82e291422 typeexpr: More optional modifier tests
Ensuring that the constraint boolean carries through to the next level
of constraint calculation after an optional() modifier.
2022-04-27 14:53:16 -04:00
Alisdair McDiarmid
dde4979c49 typeexpr: Improve diagnostic for any() constraints
Using the any keyword with arguments (e.g. any(string, bool)) is
invalid, but any is not technically a "primitive type keyword". This
commit corrects the language in the diagnostic and updates the tests.
2022-04-27 14:52:03 -04:00
Tom Bamford
7a9746e835
Changelog for #30936 2022-04-27 19:42:38 +01:00
Tom Bamford
351fd9b119
Merge pull request #30936 from hashicorp/f/azurerm-backend-oidc
backend/remote-state/azure: support OIDC authentication
2022-04-27 19:34:53 +01:00
Tom Bamford
d08bc4463d
Azure Backend: support OIDC authentication 2022-04-27 19:27:30 +01:00
Tom Bamford
807e7c0350
Update to go-azure-helpers v0.31.1 2022-04-27 19:27:30 +01:00
Alisdair McDiarmid
356cee7b89 typeexpr: Add test coverage for optional modifier 2022-04-27 14:25:42 -04:00
Alisdair McDiarmid
bf9f733ca2 typeexpr: Import tests from hashicorp/hcl
This package is a fork of the HCL ext/typeexpr package, but we dropped
the tests when bringing it across. This commit imports those tests
verbatim.
2022-04-27 14:16:33 -04:00
Alisdair McDiarmid
6956a06d63 Update CHANGELOG.md 2022-04-27 13:46:23 -04:00
Alisdair McDiarmid
b02867bed3
Merge pull request #30945 from hashicorp/alisdair/jsonstate-output-type
json-output: Add output type to JSON format
2022-04-27 13:36:43 -04:00
Alisdair McDiarmid
12c8f9498c json-output: Add output type to JSON format
Previously the supported JSON plan and state formats included only
serialized output values, which was a lossy serialization of the
Terraform type system. This commit adds a type field in the usual cty
JSON format, which allows reconstitution of the original value.

For example, previously a list(string) and a set(string) containing the
same values were indistinguishable. This change serializes these as
follows:

{
  "value": ["a","b","c"],
  "type": ["list","string"]
}

and:

{
  "value": ["a","b","c"],
  "type": ["set","string"]
}
2022-04-27 13:30:15 -04:00
Craig Wright
e217c0c53a
Merge pull request #30938 from jensenbox/patch-1
chore: Typo fix (`retuns` -> `returns`)
2022-04-26 18:32:41 -07:00
Ryoh Akiyoshi
9b4600cc23
website: Fix an example for urlencode function
The example did not reflect the actual behavior of escaping spaces.
2022-04-26 17:38:47 -07:00
Christian Jensen
85a081bd2a
chore: Typo fix
Fix a mispelled word.
2022-04-26 15:56:32 -07:00
James Bardin
7fe3768327
Merge pull request #30931 from hashicorp/jbardin/replace_triggered_by-docs
replace_triggered_by docs
2022-04-26 18:29:43 -04:00
James Bardin
0501980b46
Update website/docs/language/resources/behavior.mdx
Co-authored-by: Laura Pacilio <83350965+laurapacilio@users.noreply.github.com>
2022-04-26 18:17:58 -04:00
James Bardin
4e95b24022
Update website/docs/language/meta-arguments/lifecycle.mdx
Co-authored-by: Laura Pacilio <83350965+laurapacilio@users.noreply.github.com>
2022-04-26 18:17:52 -04:00
James Bardin
6c15cab211
Update website/docs/language/meta-arguments/lifecycle.mdx
Co-authored-by: Laura Pacilio <83350965+laurapacilio@users.noreply.github.com>
2022-04-26 18:17:46 -04:00
James Bardin
840a7437c2
Update website/docs/language/meta-arguments/lifecycle.mdx
Co-authored-by: Laura Pacilio <83350965+laurapacilio@users.noreply.github.com>
2022-04-26 18:17:41 -04:00
Sebastian Rivera
8089f090f9
Merge pull request #30858 from hashicorp/sebasslash/err-approval-input-false
Handle -input=false in cloud integration
2022-04-26 14:25:33 -04:00
Sebastian Rivera
20ba58e828 CHANGELOG: cloud integration interprets -input flag 2022-04-26 14:24:08 -04:00
Sebastian Rivera
9d7fdbea2d Handle -input=false in cloud integration
For non-interactive contexts, Terraform is typically executed with the flag -input=false.
However for runs that are not set to auto approve, the cloud integration will prompt a user for
approval input even with input being set to false. This commit enables the cloud integration to know
the value of the input flag and use it to determine whether or not to ask the user for input.

If -input is set to false and the run cannot be auto approved, the cloud integration will throw an error
stating run confirmation can no longer be handled in the CLI and that they must do so through the browser.
2022-04-26 11:17:44 -04:00
Sebastian Rivera
c557078704
Merge pull request #30917 from hashicorp/sebasslash/config-token-precedence
Give the configuration token higher precedence over the CLI config file
2022-04-26 10:23:02 -04:00
Sebastian Rivera
c7bdd28e4c CHANGELOG: Token config priority 2022-04-26 10:03:07 -04:00
James Bardin
7b40b31697 replace_triggered_by docs 2022-04-25 18:43:38 -04:00
Martin Atkins
983e40bf4a
CHANGELOG: Remove reference to "go-tfe" library upgrade
We don't typically talk about implementation details in the changelog. The content above already describes the user-visible changes that resulted from that upgrade.
2022-04-25 09:51:36 -07:00
Martin Atkins
465832f1e3
Update CHANGELOG.md 2022-04-25 09:49:03 -07:00
Martin Atkins
09ab872a6f build: go get github.com/hashicorp/hcl/v2@v2.12.0
This tagged release is a superset of the specific commit we had previously
selected, adding in just an improved error message for inconsistent result
types in a conditional expression.
2022-04-25 09:45:56 -07:00
kmoe
84e18f31bd
bump mitchellh/cli from 1.1.2 to 1.1.3 (#30914) 2022-04-25 12:06:12 +01:00