Commit Graph

30197 Commits

Author SHA1 Message Date
Liam Cervante
9f0d1d0630
terraform init: add link to documentation when a checksum is missing from the lock file (#31408)
* terraform init: add suggested fix for when a checksum is missing from the lock file

* improve error message

* add link to the documentation

* cleanup leftovers from previous attempt

* fix tests

* s/,/;

* fix imports
2022-07-20 13:28:16 +01:00
Liam Cervante
83e84e5477
terraform init: add warning and guidance when lock file is incomplete (#31399)
* terraform init: add warning and guidance when lock file is incomplete

* make the provider list in the warning deterministic

* create installer event for tracking provider lock hashes (#31406)

* create installer event for tracking provider lock hashes

* address comments

* fix tests

* improve error message

* Update internal/command/init.go

Co-authored-by: Martin Atkins <mart@degeneration.co.uk>

Co-authored-by: Martin Atkins <mart@degeneration.co.uk>
2022-07-20 13:28:04 +01:00
Liam Cervante
224728879d
Ignore existing package hashes for providers lock command (#31389)
* Ignore existing package hashes for  command

* missing new line

* Fix incorrect logic when deciding change message

* fix imports
2022-07-20 13:27:24 +01:00
Liam Cervante
afd273d636
Add goimports as a check to the Github commit actions (#31432)
* Add goimports as a check to the Github commit actions

* check diff against main instead of last commit

* goimports should fix the problems

* fix up conditionals and wildcard matching

* specify origin/main in diff

* fetch main branch when checkout

* back to origin main
2022-07-19 10:14:28 +01:00
kmoe
7b4a5513a9
command: fix panic on show when state file is invalid or unavailable (#31444) 2022-07-15 17:31:56 +01:00
kmoe
d64e6dfa09
Update CHANGELOG.md 2022-07-15 17:31:17 +01:00
hellertang
0dbf0711a0
cos backend support accelerate (#31425) 2022-07-15 17:07:41 +01:00
Alisdair McDiarmid
c4a65f8381
Update CHANGELOG.md 2022-07-14 13:17:01 -04:00
Alisdair McDiarmid
d3284bdc4e
Merge pull request #31220 from FooBartn/string-starts-ends-with-funcs
feat: add startswith and endswith funcs
2022-07-14 13:13:04 -04:00
Alisdair McDiarmid
7190898501
Apply suggestions from code review
Co-authored-by: Laura Pacilio <83350965+laurapacilio@users.noreply.github.com>
2022-07-14 13:03:53 -04:00
Joshua Barton
0dfcbe6d0c
docs: Add recommended language changes
Co-authored-by: Laura Pacilio <83350965+laurapacilio@users.noreply.github.com>
2022-07-14 11:06:35 -05:00
Jeff Bonhag
f30738d965
Add golden reference test for JSON plan (#31362)
* Add golden JSON test for Terraform plan

* Add data source to golden JSON plan

* Move output comparison code into shared helper function

* Add note for maintainer to contact TFC when UI changes

UI changes may potentially impact the behavior of structured run output
on TFC.

* Add test_data_source to other mock providers
2022-07-12 17:00:36 -04:00
Sarah French
5e000c2741
Merge pull request #31398 from hashicorp/fix-glossary-table-contents
Fix links in Glossary page's table of contents
2022-07-12 15:59:26 +01:00
Tom Bamford
04e1fa088e
Changelog for #31070 2022-07-12 12:21:11 +01:00
Tom Bamford
dc1f5bccf8
Merge pull request #31070 from hashicorp/f/removing-adal-auth
backend/azurerm: exclusively using Microsoft Graph/MSAL and removing Azure Active Directory Graph/ADAL
2022-07-12 12:18:29 +01:00
Laura Pacilio
06baea9ae1
Merge pull request #31286 from BrianSidebotham/update_docs_for_30072
Fixes #30072 - Update docs to show single file usage
2022-07-11 11:07:19 -04:00
Craig Wright
a30d1c475c
Merge pull request #31403 from hashicorp/backport/cstella84/patch-add-hyperlink-for-referenced-argument
Added link to "hostname" argument
2022-07-08 12:11:02 -07:00
Brian Sidebotham
a6aa75931b Update internal/command/fmt.go
Co-authored-by: Laura Pacilio <83350965+laurapacilio@users.noreply.github.com>
2022-07-08 09:22:22 -07:00
Brian Sidebotham
26e770321f Update website/docs/cli/commands/fmt.mdx
Co-authored-by: Laura Pacilio <83350965+laurapacilio@users.noreply.github.com>
2022-07-08 09:19:50 -07:00
Brian Sidebotham
7dd199cbd0 Fixes #30072 - Update documentation to show that the old DIR option can target a single file instead 2022-07-08 09:19:50 -07:00
Radek Simko
7feef1c4aa
Use hashicorp/terraform-registry-address as a decoupled library (#28338)
* refactor: Use tfaddr for provider address parsing

* refactor: Use tfaddr for module address parsing

* deps: introduce hashicorp/terraform-registry-address
2022-07-08 14:46:29 +01:00
Chris Stella
9e3535be9c
Added link to "hostname" argument
There should be a link to the argument being referenced for clarity and completeness.
2022-07-07 23:02:45 -07:00
Martin Atkins
de8eef1da5 addrs: Format string instance keys in an HCL-compatible way
So far we've only ever needed to re-parse address strings that happen not
to contain instance keys and so we've gotten away with our serialization
of these not being quite right, but given how liberally we've expected to
be able to use address strings from this package for wire format
interchange it seems likely that this is going to surprise us eventually.

Now we'll use an escaping scheme compatible with HCL's parser rather
than Go's parser, and so we can safely rely on hclsyntax.ParseTraversal
as part of reversing this operation to transform an address string back
into an address equivalent to the value it was created from.
2022-07-07 14:05:48 -07:00
Sarah French
892100a4cf
Update glossary.mdx 2022-07-07 14:46:56 +01:00
Sarah French
a8738731ba
Update glossary.mdx 2022-07-07 14:42:27 +01:00
Laura Pacilio
aeefde7428
Merge pull request #31364 from timgates42/bugfix_typos
docs: Fix a few typos
2022-07-06 17:03:09 -04:00
hc-github-team-tf-core
43027e92ae Cleanup after v1.3.0-alpha20220706 release 2022-07-06 18:26:37 +00:00
hc-github-team-tf-core
410daca668
Release v1.3.0-alpha20220706 2022-07-06 18:14:49 +00:00
James Bardin
9cfe1a5ce8 update CHANGELOG.md 2022-07-06 13:57:33 -04:00
James Bardin
1fba244d3a
Merge pull request #31179 from hashicorp/jbardin/plan-destroy
Call PlanResourceChange for destroy operations
2022-07-06 13:57:13 -04:00
James Bardin
30369650a7
Merge pull request #31343 from hashicorp/jbardin/mock-replace
remove go.mod replacement of `github.com/golang/mock`
2022-07-06 13:49:38 -04:00
James Bardin
26c569e384 s/Capabilities/ServerCapabilities/ 2022-07-06 13:47:35 -04:00
James Bardin
fd742cd544 add e2e test with provider schema capabilities
enable destroy planning for the simple providers used in the e2e tests
2022-07-06 13:47:35 -04:00
James Bardin
6706d52832 check PlanDestroy capability in plugins
This is most easily handled in the plugin code, without involving
Terraform core.

The biggest change here other than checking the PlanDestroy capability,
is the removal of the schema helper methods in the plugins. With the
addition of the capabilities field, combined with the necessity of
checking diagnostics from the schema, the helpers have outlived their
usefulness. Perhaps there's a better pattern for these repetitive calls,
but for now there isn't too extra verbosity involved.
2022-07-06 13:47:35 -04:00
James Bardin
b9f1a5ac57 add Schema Capabilities to protocol 2022-07-06 13:47:35 -04:00
James Bardin
9487cfba28 add test for planned private data in destroy 2022-07-06 13:47:35 -04:00
James Bardin
96c720517f fixup broken test fixtures
some of the minimal test provider implementations didn't check for null
values.
2022-07-06 13:47:35 -04:00
James Bardin
acba1159e4 add provider metas to destroy plan 2022-07-06 13:47:35 -04:00
James Bardin
ccd2c7820a plan resource destroy
Call PlanResourceDestroy during a destroy plan.

This allows providers two new abilities:
- They can evaluate if the plan is valid, notifying users of any
  potential errors before an apply is started, which may not be able to
  complete.
- They can inspect and modify their private data during a destroy plan
  just like they can with an other plan operation.
2022-07-06 13:47:35 -04:00
James Bardin
e95bfe6d19 fix test mocks to behave when planning destroys 2022-07-06 13:47:35 -04:00
Joshua Barton
2278d30857 docs: add documentation for starts and endswith 2022-07-06 10:56:32 -05:00
Laura Pacilio
a52b44f0bc
Merge pull request #31385 from hashicorp/fix-readme-again
Update README.md
2022-07-05 18:08:37 -04:00
Laura Pacilio
ccb466f3b1
Update README.md 2022-07-05 18:02:19 -04:00
Craig Wright
e3daf4c2a6
Merge pull request #31354 from chtitux/patch-1
Update docs/cli/commands/init: add backtick to readonly value
2022-07-05 14:56:19 -07:00
Laura Pacilio
2daee48675
Merge pull request #31351 from hashicorp/update-format-function-page
Update format function to mention list, map, and null types
2022-07-05 17:45:11 -04:00
Laura Pacilio
7a11e87631 Add example! 2022-07-05 17:32:39 -04:00
Laura Pacilio
15b59fd6c9 Reorder page items and add note about available types to specific verb descriptions 2022-07-05 17:25:08 -04:00
James Bardin
1214a16a63
Merge pull request #31347 from hashicorp/jbardin/remove-etcdv3
remove deprecated etcdv3 backend
2022-07-05 11:50:02 -04:00
Laura Pacilio
8fac3d63d8
Merge pull request #31310 from ianmrose-cm/main
Add shell explanation to remote-exec `inline` argument documentation.
2022-07-05 10:47:12 -04:00
CJ
e6d1716644
Merge pull request #31379 from hashicorp/fix-cdktf-link
Fix Broken CDKTF Link on Terraform Tools page
2022-07-05 09:35:51 -05:00