Commit Graph

30708 Commits

Author SHA1 Message Date
Michael Matloka
28d7a685a9
Add missing HCL syntax highlighting in composition.mdx 2022-12-30 00:36:19 +01:00
James Bardin
0e46d0ad25
Merge pull request #32424 from hashicorp/jbardin/reify-null-blocks
fix invalid null blocks during refresh
2022-12-21 13:17:41 -05:00
James Bardin
d493e998e1 add resource address to log message 2022-12-21 10:53:11 -05:00
James Bardin
a6098b67fa fix test state 2022-12-21 10:47:07 -05:00
James Bardin
0c1aaba635 fix invalid null blocks during refresh
Legacy providers may return null values for nested blocks during
refresh. Because the ReadResource call needs to accept any value to
allow the provider to report external changes, we allowed all changes to
the value as long as the underlying cty.Type was correct, allowing
null block values to be inserted into the state.

While technically invalid, we needed to accept these null values for
compatibility, and they were mostly seen as a nuisance, causing noise in
external changes and plan output. These null block values however can be
inserted into the effective configuration with the use of
`ignore_changes`, which can cause problems where the configuration is
assumed to be completely valid.

Rather than accept the null values, we can insert empty container values
for these blocks when refreshing the instance, which will prevent any
invalid values from entering state at all. Because these must still be
accepted for compatibility, we can only log the difference as a warning.
Currently the NormalizeObjectFromLegacySDK does not report which
specific blocks it fixed, so we just log a generic message.
2022-12-21 10:18:26 -05:00
Craig Wright
898b0aa78b
Merge pull request #32404 from stefansundin/add-missing-apt-repos
website: add missing Ubuntu apt repositories jammy and kinetic to the list
2022-12-19 17:15:27 -08:00
Stefan Sundin
a4a1f47027 Add missing Ubuntu apt repositories jammy and kinetic to the list. 2022-12-16 21:57:26 -08:00
James Bardin
49a0eb5ed8 update CHANGELOG.md 2022-12-16 15:32:33 -05:00
James Bardin
5605f20686 update CHANGELOG.md 2022-12-16 15:30:37 -05:00
James Bardin
25ac4d33e4
Merge pull request #31633 from brittandeyoung/f-workspace-selectornew
New Terraform Workspace select flag: `-or-create`
2022-12-16 15:29:25 -05:00
Brittan DeYoung
8881418c99
Update internal/command/workspace_select.go
Co-authored-by: James Bardin <j.bardin@gmail.com>
2022-12-16 15:03:46 -05:00
James Bardin
d60d247e40
Merge pull request #31318 from twittyc/twittyc/terraformWorkspaceInvalidArgsReturnsNon0
Bug fix: Terraform workspace command returns zero exit code when given an invalid argument.
2022-12-16 13:16:56 -05:00
James Bardin
3cda7a0269
Merge pull request #29520 from ComBin/main
Don't show symbols while input if variable marked as sensitive
2022-12-16 13:13:33 -05:00
Liam Cervante
6af6540233
Use the apparentlymart/go-versions library to parse module constraints (#32377)
* Use the apparentlymart/go-versions library to parse module constraints

* goimports

* Update comments, and parse versions carefully

* add acceptance tests to verify behaviour of partial matches

* goimports
2022-12-14 17:02:11 +01:00
James Bardin
a9230c9e75 update CHANGELOG.md 2022-12-12 15:20:58 -05:00
James Bardin
404b284911
Merge pull request #31757 from hashicorp/jbardin/terraform-data
New `terraform_data` managed resource to replace `null_resource`
2022-12-12 15:17:02 -05:00
Conor Evans
e206d4e83e
fix(unlock): amend force-unlock description (#32363)
Signed-off-by: Conor Evans <coevans@tcd.ie>

Signed-off-by: Conor Evans <coevans@tcd.ie>
2022-12-09 16:15:27 +00:00
Bryan Stenson
b2f6813341
typo (#32327) 2022-12-09 16:14:01 +00:00
The Terraform Team
7d57d59959 Automated equivalence test golden file update for release v1.4.0-alpha20221207. 2022-12-07 15:19:56 +00:00
hc-github-team-tf-core
e4e0322d2a Cleanup after v1.4.0-alpha20221207 release 2022-12-07 15:08:58 +00:00
hc-github-team-tf-core
cf0cdf680c
Release v1.4.0-alpha20221207 2022-12-07 14:54:15 +00:00
kmoe
5c8208df34
build with Go 1.19.4 (#32351) 2022-12-07 14:32:56 +00:00
kmoe
d26e79c0d3
Update CHANGELOG.md 2022-12-07 14:15:03 +00:00
hellertang
9dbaac5975
add accelerate (#32344) 2022-12-07 10:05:42 +00:00
Matthew Garrell
6ebc30ddcb
Merge pull request #32007 from alloveras/patch-1
The NETRC environment variable is honoured
2022-12-06 13:16:25 -05:00
James Bardin
d0d6501c1f s/trigger/triggers_replace/
Rename `triggers` to be more descriptive, making it similar to
`replace_triggered_by`.
2022-12-05 15:23:57 -05:00
James Bardin
58e15c7f0e add terraform_data e2e test 2022-12-05 15:23:57 -05:00
James Bardin
3b73ed3348 new terraform_data managed resource
Replace and enhance the `null_resource` functionality with a new
`terraform_data` managed resource.
2022-12-05 15:23:57 -05:00
Alisdair McDiarmid
e0b226a3b8
Update CHANGELOG.md 2022-12-05 10:05:27 -05:00
Alisdair McDiarmid
80fddc431e
Merge pull request #32295 from xiaozhu36/xiaozhu
backend/oss: Ignore the getting oss endpoint error and using string concat instead; Improves the error message level
2022-12-05 10:03:20 -05:00
xiaozhu36
ec62ca1b70 backend/oss: Ignore the getting oss endpoint error and using string concat instead; Improves the error message level 2022-12-04 11:51:29 +08:00
HashiBot
6d9dc22834
chore: Update Digital Team Files (#32322)
* Update generated scripts (should-build.sh)

* Update generated website Makefile

* Update generated scripts (website-build.sh)

* Update generated scripts (website-start.sh)
2022-12-02 10:24:25 -05:00
Liam Cervante
2325ec716c
Update Terraform equivalence tests to remove unneeded input. (#32288)
* test

* update equivalence testing framework version

* Remove debugging statements

* remove more debugging statements

* s/liamcervante/hashicorp/g

* remove and update deprecated set-output statements
2022-12-02 11:22:02 +01:00
James Bardin
07e2d56050 update CHANGELOG.md 2022-12-01 10:27:04 -05:00
James Bardin
cbcae8478f
Merge pull request #32209 from hashicorp/jbardin/data-source-destroy-edges
ensure destroy edges from data sources
2022-12-01 10:25:42 -05:00
James Bardin
23aaa39747
Merge pull request #32308 from hashicorp/jbardin/output-eval-fix
always evaluate outputs from state during apply
2022-12-01 09:33:31 -05:00
James Bardin
c66a797f2a
Merge pull request #32307 from hashicorp/jbardin/output-perf
don't re-set changes for refreshed outputs
2022-11-30 14:06:50 -05:00
Martin Atkins
e216b8180f
Update CHANGELOG.md 2022-11-29 17:47:55 -08:00
Martin Atkins
e039a012c2
Update CHANGELOG.md 2022-11-29 17:47:22 -08:00
Martin Atkins
8253821e56 go get github.com/zclconf/go-cty-yaml@v1.0.3
This includes the fix for a bug in what Terraform calls the "yamldecode"
function, where it was not correctly handling any situation where the
decode result is a null value. It was previously returning an unknown
value in that case, whereas now it returns a null value as expected.
2022-11-29 17:45:45 -08:00
Laura Pacilio
1ce0b91e67
Merge pull request #32020 from hashicorp/fix-future-lang-2
Remove future-facing language from docs (WIP)
2022-11-29 15:09:21 -05:00
Laura Pacilio
97f9cb1645 Remove unnecessary explanation 2022-11-29 15:00:36 -05:00
Laura Pacilio
a76b634f82
Update website/docs/internals/json-format.mdx 2022-11-29 14:56:58 -05:00
Liam Cervante
c1633436b8
Add more equivalence test cases (#32296) 2022-11-29 12:36:52 +01:00
James Bardin
dcd762e81d evaluate outputs from state
Outputs were being evaluated from changes, even during apply. Make sure
we update the state correctly, and remove the existing change. This
requires adding more Planning fields to the output nodes to
differentiate whether the output is being planned or applied because the
same type handles both cases. We can evaluate separately whether new
types should be introduced to deal with both cases.

The module node cleanup was also prematurely removing module outputs
from the state before evaluation. This was not noticed before because
the evaluation was always falling back to changes. Have the root module
node do the final cleanup for all its children.

It turns out sensitive was also being handled incorrectly, and only
sensitive from configuration was being considered. Make sure to mark the
output as sensitive when storing sensitive values into state, and OR
sensitive marks with the state config when evaluating the output values.
2022-11-28 16:39:55 -05:00
James Bardin
c9d6f82ac5 don't re-set changes for refreshed outputs
When output values are updated in the refreshed state, we don't need to
re-set the changes which were already set in conjunction with the
current state.
2022-11-28 16:37:23 -05:00
alisdair
ec6451a82a
Merge pull request #31999 from JarrettSpiker/jspiker/workspace-delete-rum-docs
Update workspace delete command docs to reference RUM vs empty state
2022-11-25 12:07:02 -05:00
Jarrett Spiker
21d98697cb Add manual line breaks to workspace delete command help text 2022-11-25 11:42:22 -05:00
Liam Cervante
37b88b33ce
Rollout equivalence testing during Terraform releases and builds (#31928)
* add some basic equivalence tests and execute them in the build pipeline

* remove old file, now unused

* update terraform-equivalence-testing to v0.2.0

* add separate action

* make sure to read from hashicorp repo

* remove elevated github token where possible

* Don't need elevated token anymore

* update with official mock provider

* last change: don't need the authorization header for public repositories.
2022-11-24 14:00:08 +01:00
Jarrett Spiker
1e1312fb78 Remove use of RUM acronymn in workspace delete docs 2022-11-22 15:10:58 -05:00