Commit Graph

25830 Commits

Author SHA1 Message Date
James Bardin 449ea72e87 update CHANGELOG.md 2020-03-03 13:48:19 -05:00
Pam Selle 6a4cfa18da Coverage 2020-03-03 13:01:05 -05:00
findkim 4f55721c2e registry: setup client logger 2020-03-03 11:22:34 -06:00
Pam Selle 809d34e5b2 Add codecov 2020-03-03 12:19:07 -05:00
Pam Selle 2b2ff24404 Add 0.12 branch to travis list 2020-03-03 12:16:14 -05:00
findkim a3f26ccd12 website/docs/commands: document TF_REGISTRY_DISCOVERY_RETRY 2020-03-03 10:08:36 -06:00
James Bardin a3be47584a
Merge pull request #24254 from hashicorp/jbardin/state-mv
state mv should always use target address to determine each mode.
2020-03-03 10:21:03 -05:00
Pam Selle 430b7c8da6
Merge pull request #24249 from hashicorp/config-package-deletions
Deletions in the config package
2020-03-02 16:11:53 -05:00
Pam Selle 1a8e7cbd1b Move the commit along with 2020-03-02 15:56:38 -05:00
Pam Selle fa3b54c0c4 Move type construction out, delete func 2020-03-02 15:54:50 -05:00
Pam Selle dd6fb16971 Deletions in the config package 2020-03-02 15:35:35 -05:00
James Bardin 10d926904f state mv should always target instance each mode
When doing a state mv of an instance, the resulting each mode should
always be taken from the target address.
2020-03-02 14:45:03 -05:00
Pam Selle c4441661b0
Merge pull request #24227 from zzhai/patch-1
Update remote.html.md
2020-03-02 13:04:49 -05:00
zzhai 687d74786f
Update remote.html.md
A minor typo
2020-02-26 12:19:10 -08:00
Martin Atkins f899f5aa42 command/init: new error message for signature verification failure
Our initial Terraform 0.13.0 release will continue to support only the
hard-coded official HashiCorp signing key, with support for other keys to
follow in a later release once the trust infrastructure is in place to
support that.

This change is intended to (marginally) improve the UX for a possible
future situation where a HashiCorp-distributed provider makes a released
signed with a new key and a prior version of Terraform ends up trying to
install it due to incorrect version constraints. With this new text we
hope to give the user a better prompt for onward troubleshooting, but
in a sort of hedging way because we have not yet finalized the details of
how new keys might roll out in practice.

Hopefully a user seeing this message would consult the release notes for
Terraform itself and for the provider in question and find some
as-yet-undetermined information about how to proceed.

If the decentralized trust model design comes together before the v0.13.0
release then we may make further amendments here to prepare for that, but
that work should not block the v0.13.0 release if other work concludes
first.
2020-02-25 10:31:54 -05:00
Martin Atkins 8eff19e48f internal/getproviders: Initial implementation of FilesystemMirrorSource
This is a basic implementation of FilesystemMirrorSource for now aimed
only at the specific use-case of scanning the cache of provider plugins
Terraform will keep under the ".terraform" directory, as part of our
interim provider installer implementation for Terraform 0.13.

The full functionality of this will grow out in later work when we
implement explicit local filesystem mirrors, but for now the goal is to
use this just to inspect the work done by the automatic installer once
we switch it to the new provider-FQN-aware directory structure.

The various FIXME comments in this are justified by the limited intended
scope of this initial implementation, and they should be resolved by
later work to use FilesystemMirrorSource explicitly for user-specified
provider package mirrors.
2020-02-25 10:30:03 -05:00
Martin Atkins c073db09ea internal/getproviders: Sorting and filtering for lists of PackageMeta
These are utility functions to ease processing of lists of PackageMeta
elsewhere, once we have functionality that works with multiple packages
at once. The local filesystem mirror source will be the first example of
this, so these methods are motivated mainly by its needs.
2020-02-25 10:30:03 -05:00
Martin Atkins d82a36b6f5 internal/getproviders: ParsePlatform method
This is just to have a centralized set of logic for converting from a
platform string (like "linux_amd64") to a Platform object, so we can do
normalization and validation consistently.
2020-02-25 10:30:03 -05:00
Martin Atkins 3078d21c5f internal/getproviders: Include Provider and Version in PackageMeta
Although we tend to return these in contexts where at least one of these
values is implied, being explicit means that PackageMeta values are
self-contained and less reliant on such external context.
2020-02-25 10:30:03 -05:00
Martin Atkins b53e3074cf addrs: Provider.LessThan
When making lists of providers (or lists that contain providers) it's
helpful to have a canonical ordering in order to produce deterministic
results.

This ordering has no semantic meaning and is just here for the sake of
having a predictable standard.
2020-02-25 10:30:03 -05:00
Martin Atkins 49498759e2
Update CHANGELOG.md 2020-02-25 10:23:23 -05:00
Martin Atkins 67d95b97ce lang/funcs: templatefile requires valid variable names
Previously the templatefile function would permit any arbitrary string as
a variable name, but due to the HCL template syntax it would be impossible
to refer to one that isn't a valid HCL identifier without causing an
HCL syntax error.

The HCL syntax errors are correct, but don't really point to the root
cause of the problem. Instead, we'll pre-verify that the variable names
are valid before we even try to render the template, and given a
specialized error message that refers to the vars argument expression as
the problematic part, which will hopefully make the resolution path
clearer for a user encountering this situation.

The syntax error still remains for situations where all of the variable
names are correct but e.g. the user made a typo referring to one, which
makes sense because in that case the problem _is_ inside the template.
2020-02-25 10:19:46 -05:00
Martin Atkins ec9f950b3f lang/funcs: Test actual error messages from templatefile
This function has a number of different error cases with hopefully-helpful
error messages for each, so it's good to test we're getting the error
message we were actually expecting in each case.
2020-02-25 10:19:46 -05:00
Chris Griggs 447fb6146f
Merge pull request #24175 from hashicorp/cgriggs01-quorum
[Website] update provider links
2020-02-25 07:14:17 -08:00
Pam Selle c249943360
Module Expansion: Part 2 (#24154)
* WIP: dynamic expand

* WIP: add variable and local support

* WIP: outputs

* WIP: Add referencer

* String representation, fixing tests it impacts

* Fixes TestContext2Apply_outputOrphanModule

* Fix TestContext2Apply_plannedDestroyInterpolatedCount

* Update DestroyOutputTransformer and associated types to reflect PlannableOutputs

* Remove comment about locals

* Remove module count enablement

* Removes allowing count for modules, and reverts the test,
while adding a Skip()'d test that works when you re-enable
the config

* update TargetDownstream signature to match master

* remove unnecessary method

Co-authored-by: James Bardin <j.bardin@gmail.com>
2020-02-24 17:42:32 -05:00
Martin Atkins d095f57290
Update CHANGELOG.md 2020-02-20 18:16:54 -08:00
Nick Fagerlund 758bf8500c website: Label backend data source examples as "data source configuration"
"Example referencing" was ambiguous and confusing, especially since these
sections don't show how to reference an output in an expression.
2020-02-20 14:45:04 -08:00
Chris Griggs d9a70a388a
Fixit 2020-02-20 09:33:17 -08:00
Chris Griggs f39b41b275 [Website] update provider links 2020-02-20 09:21:29 -08:00
James Bardin bf65b516c0
Merge pull request #24163 from hashicorp/jbardin/destroy-provisioner-keys
Destroy provisioner each.key
2020-02-20 08:41:55 -05:00
Martin Atkins 98336e6e81
Update CHANGELOG.md 2020-02-19 16:00:57 -08:00
Yuri Astrakhan 6eb968531d
backend/plan: Show warnings even if no changes are needed 2020-02-19 15:59:15 -08:00
Pam Selle 9a65e02b20
Update version.go 2020-02-19 17:42:33 -05:00
James Bardin 745d4e76ec better comments 2020-02-19 16:54:41 -05:00
James Bardin 0d6b5f1559 update some destroy provisioner tests to use for_each 2020-02-19 16:02:40 -05:00
James Bardin 953ada1cf8 destroy provisioner cannot re-evaluate for_each
During destroy, the for expression may be unknown and evaluation will
fail. Destroy provisioners however can only reference the key value,
which is known in the address.
2020-02-19 16:02:40 -05:00
James Bardin 8421abaca0 Add InstanceKey.Value method
Have the InstanceKey implementations handle their own cty.Value
conversions.
2020-02-19 16:02:40 -05:00
James Bardin 46212a6ca5
Merge pull request #23811 from hashicorp/jbardin/dag
some basic dag optimizations
2020-02-19 15:20:24 -05:00
James Bardin 37a7d904aa dag benchmark 2020-02-19 14:53:19 -05:00
James Bardin 1b45b744c3 remove json2dot command
There's no need for the json2dot command since we can't create json
debug graphs.
2020-02-19 14:53:19 -05:00
James Bardin 2e489d88f3 update terraform to work with new dag changes
Also removing unnecessary uses of the Set.List
2020-02-19 14:53:19 -05:00
James Bardin 0c1ab6142b remove debug code
Remove the abandoned graph debugger
2020-02-19 14:53:19 -05:00
James Bardin 6096371068 remove all unneeded list-based iteration
Make the default walks always use the sets directly, which avoids
repeated copying of every set into a new slice.
2020-02-19 14:53:19 -05:00
James Bardin 26a4de803f remove uses of Set.List
Since the set can be iterated over directly, we no longer need to copy
the values into a new slice.
2020-02-19 14:53:19 -05:00
James Bardin 32ae3b5452 make dag.Set a simple map
This allows iteration directly over the set, removing the need to
allocate and copy a new slice for every iteration.
2020-02-19 14:46:35 -05:00
Pam Selle 991ee37cee
Update CHANGELOG.md 2020-02-19 13:28:06 -05:00
tf-release-bot 39ce190852 Cleanup after v0.12.21 release 2020-02-19 18:18:47 +00:00
Mathias Lafeldt 1f3a2c0e02
backend/remote-state/oss: Add test revealing bug in state locking 2020-02-19 11:41:56 +01:00
Chris Griggs 5f27856766
Merge pull request #24156 from hashicorp/cgriggs01-baiducloud-docs
[Website] add new provider links
2020-02-18 17:09:29 -08:00
im2nguyen 4f10504ca0
website: add token setup callout to remote backend docs (#24109) 2020-02-18 16:28:12 -08:00