Commit Graph

25175 Commits

Author SHA1 Message Date
Pam Selle 285e545735
Merge pull request #23414 from gechr/gc-fix-trim-func-mappings
lang: Fix new `trim*` function mappings
2019-11-19 15:01:34 -05:00
George Christou 23fc68cc91
lang: Fix new `trim*` function mappings
Fixes #23413
2019-11-19 10:13:14 +00:00
tf-release-bot 6470a56fac Cleanup after v0.12.16 release 2019-11-18 22:20:57 +00:00
tf-release-bot d54ddd5dc9
v0.12.16 2019-11-18 22:09:27 +00:00
James Bardin c8857bf54e update CHANGELOG.md 2019-11-18 16:56:55 -05:00
James Bardin 5a113db84c
Merge pull request #23399 from hashicorp/jbardin/cbd-cycle
CBD GraphNodeCreators cannot depend on GraphNodeDestroyers
2019-11-18 16:54:25 -05:00
Nick Fagerlund 6af552bea6 website: interpolation: clean up more placeholder formatting 2019-11-18 12:32:51 -08:00
Carlos Vega Meyer fa22084e3a website: interpolation.html.md: "module" is literal
`MODULE` should be lowercase since it's not a placeholder for the actual module name.
2019-11-18 12:32:51 -08:00
James Bardin 33bef7c42e don't append refreshed state dependencies
EvalRefreshDependencies is used to update resource dependencies when
they don't exist, allow broken or old states to be updated. While
appending any newly found dependencies is tempting to have the largest
set available, changes to the config could conflict with the prior
dependencies causing cycles.
2019-11-18 09:32:57 -05:00
Kristin Laemmert 9ddc9c79a4
Update CHANGELOG.md 2019-11-18 08:32:31 -05:00
George Christou 91100c003c lang/funcs: Add more `trim*` functions (#23016)
* lang/funcs: Add `trim*` functions
2019-11-18 08:31:44 -05:00
sclaire-1 13fe1f8b47
Edit BUILDING.md
Split a sentence under the  "Versioning" section into two sentences to improve flow
2019-11-17 15:04:22 -08:00
James Bardin 682083cdd1 Creators cannot depend directly on CBD dest nodes
Since a create node cannot both depend on its destroy node AND be
CreateBeforeDestroy, the same goes for its dependencies. While we do
connect resources with dependency destroy nodes so that updates are
ordered correctly, this ordering does not make sense in the
CreateBeforeDestroy case.

If resource node is CreateBeforeDestroy, we need to remove any direct
dependencies from it to destroy nodes to prevent cycles. Since we don't
know for certain if a crate node is going to be CreateBeforeDestroy at
the time the edge is added in the graph, we add it unconditionally and
prune it out later on. The pruning happens during the CBD transformer
when the CBD destroy node reverses it's own destroy edge.  The reason
this works for detecting the original edge, is that dependencies of CBD
resources are forced to be CBD themselves. This does have a false
positive where the case of the original node is NOT CBD, but this can be
taken care of later when we gather enough information in the graph to
prevent the connection in the first place.
2019-11-17 09:56:44 -05:00
James Bardin 71f4526ae5 failing test for cbd cycle 2019-11-17 09:55:32 -05:00
Pam Selle 04c5547766
Update CHANGELOG.md 2019-11-15 15:32:49 -05:00
Pam Selle 5223aa35ba
Merge pull request #23398 from hashicorp/b-windows-tfignore
[deps] Update go-tfe
2019-11-15 15:31:20 -05:00
Pam Selle 1077f01e08 Point to updated go-tfe 2019-11-15 14:14:17 -05:00
Kristin Laemmert 8432ebbcbc
Update CHANGELOG.md 2019-11-15 11:05:09 -05:00
Kristin Laemmert 2c78414724
configs/configupgrade: do not panic when int value is out of range (#23394)
`terraform 0.12upgrade` assumes that the configuration has passed 0.11
init, but did not explicitly check that the configuration was valid.
Certain issues would not get caught because the configuration was
syntactically valid. In this case, int or float values out of range
resulted in a panic from `Value()`.

Since running a 0.11 validate command is a breaking change, this PR
merely moves the `Value()` logic for ints and floats into `configupgrade` so
the error can be returned to the user, instead of causing a panic.
2019-11-15 11:02:59 -05:00
Simon Brady 7a9fa93724 command/plan: Fix panic in plan output with string containing null and whitespace (#23102)
* command/plan: Fix panic in plan output with string containing null and whitespace
* command/format: add test for null string with whitespace
2019-11-15 10:25:49 -05:00
tf-release-bot 9451f8ae74 Cleanup after v0.12.15 release 2019-11-14 23:16:20 +00:00
tf-release-bot 30637c9c90
v0.12.15 2019-11-14 23:04:48 +00:00
Martin Atkins a020cf67c4
Update CHANGELOG.md 2019-11-14 14:56:56 -08:00
Martin Atkins d0f50ff83f command: Don't treat config warnings as errors
Meta.backendConfig was incorrectly treating the second return value from
loadBackendConfig as if it were go "error" rather than
tfdiags.Diagnostics, which in turn meant that it would treat warnings like
errors.

This had confusing results because it still returned that
tfdiags.Diagnostics value in its own diagnostics return value, causing the
caller to see warnings even though the backendConfig function had taken
the error codepath.
2019-11-14 14:50:51 -08:00
tf-release-bot beded11422 Cleanup after v0.12.14 release 2019-11-13 22:33:48 +00:00
tf-release-bot d1ad2a7e7b
v0.12.14 2019-11-13 22:22:31 +00:00
Chris Griggs 73a455240b
Merge pull request #23359 from hashicorp/cgriggs01-huaweucloudstack
[Website] Add huawei links
2019-11-13 12:48:35 -08:00
cgriggs01 5188f5d5c4 add huawei links 2019-11-13 09:18:26 -08:00
Pam Selle 72f39c49d2
Update CHANGELOG.md 2019-11-13 11:36:24 -05:00
Robert Tillery af77d1d22c backend/remote: Filter environment variables when loading context (#23358)
* backend/remote: Filter environment variables when loading context

Following up on #23122, the remote system (Terraform Cloud or
Enterprise) serves environment and Terraform variables using a single
type of object. We only should load Terraform variables into the
Terraform context.

Fixes https://github.com/hashicorp/terraform/issues/23283.
2019-11-13 11:34:09 -05:00
Martin Atkins b09626b0cc
Update CHANGELOG.md 2019-11-13 08:05:27 -08:00
Martin Atkins 91752f02da configs: Warn for deprecated interpolation and quoted type constraints
Following on from de652e22a26b, this introduces deprecation warnings for
when an attribute value expression is a template with only a single
interpolation sequence, and for variable type constraints given in quotes.

As with the previous commit, we allowed these deprecated forms with no
warning for a few releases after v0.12.0 to ensure that folks who need to
write cross-compatible modules for a while during upgrading would be able
to do so, but we're now marking these as explicitly deprecated to guide
users towards the new idiomatic forms.

The "terraform 0.12upgrade" tool would've already updated configurations
to not hit these warnings for those who had pre-existing configurations
written for Terraform 0.11.

The main target audience for these warnings are newcomers to Terraform who
are learning from existing examples already published in various spots on
the wider internet that may be showing older Terraform syntax, since those
folks will not be running their configurations through the upgrade tool.
These warnings will hopefully guide them towards modern Terraform usage
during their initial experimentation, and thus reduce the chances of
inadvertently adopting the less-readable legacy usage patterns in
greenfield projects.
2019-11-13 07:55:55 -08:00
Calle Pettersson 73d574913d configs: Mention leading underscores in invalid identifier message 2019-11-11 16:22:33 -08:00
sixcorners ae5f43ba25 build: Don't create apk cache in "full" docker image 2019-11-11 16:04:23 -08:00
Martin Atkins f9424194e9
Update CHANGELOG.md 2019-11-11 15:27:14 -08:00
aqche bcaf7f7ba7 states/statemgr: Properly return error when Unlock detects invalid lock id 2019-11-11 15:24:53 -08:00
Martin Atkins 61a760938f
Update CHANGELOG.md 2019-11-11 10:26:05 -08:00
Martin Atkins 79dc808614 configs: Emit warnings for deprecated quoted references/keywords
Terraform 0.12.0 removed the need for putting references and keywords
in quotes, but we disabled the deprecation warnings for the initial
release in order to avoid creating noise for folks who were intentionally
attempting to maintain modules that were cross-compatible with both
Terraform 0.11 and Terraform 0.12.

However, with Terraform 0.12 now more widely used, the lack of these
warnings seems to be causing newcomers to copy the quoted versions from
existing examples on the internet, which is perpetuating the old and
confusing quoted form in newer configurations.

In preparation for phasing out these deprecated forms altogether in a
future major release, and for the shorter-term benefit of giving better
feedback to newcomers when they are learning from outdated examples, we'll
now re-enable those deprecation warnings, and be explicit that the old
forms are intended for removal in a future release.

In order to properly test this, we establish a new set of test
configurations that explicitly mark which warnings they are expecting and
verify that they do indeed produce those expected warnings. We also
verify that the "success" tests do _not_ produce warnings, while removing
the ones that were previously written to succeed but have their warnings
ignored.
2019-11-11 10:17:34 -08:00
Martin Atkins 2423f266fb website: example of "terraform taint" with a grandchild module
I've seen folks ask about how to express this in resource address syntax
a number of times now, so adding this example here to illustrate how it
looks when there are multiple levels of module to traverse through.

This is redundant with other information further up the page, but having
it as an entirely separate example gives an opportunity to include more
introductory text to explain what the example is showing.
2019-11-11 10:12:11 -08:00
Martin Atkins 6f66aad032
Update CHANGELOG.md 2019-11-08 16:42:42 -08:00
Ethan 6833ac290b command: Use full URL for the download page when prompting for upgrade
This makes it more likely that a terminal emulator will detect the URL as a clickable link.
2019-11-08 16:10:39 -08:00
Martin Atkins b5830484b8
Update CHANGELOG.md 2019-11-08 16:06:31 -08:00
Thayne McCombs a895a42f85 command/format: fix missing elements at the end of lists in diffs 2019-11-08 16:05:23 -08:00
Chris Griggs 3e00447789
Merge pull request #23327 from hashicorp/cgriggs01-website
[Website] Provider links
2019-11-08 14:37:22 -08:00
cgriggs01 ebb0ca2d23 [Website] Provider links 2019-11-08 14:33:04 -08:00
Chris Griggs 89dbb52191
Merge pull request #23323 from hashicorp/cgriggs01-vthunder
[Website] vThunder links
2019-11-08 10:40:54 -08:00
cgriggs01 4a46d0c212 [Website] vThunder links 2019-11-08 10:18:07 -08:00
Yuki Ito 72c910cebc website: Fix typographical errors in the docs for base64sha256/512 2019-11-08 09:43:27 -08:00
Martin Atkins 515163d8e8
Update CHANGELOG.md 2019-11-08 09:42:06 -08:00
Parviz 6eaf1c23f9 lang/funcs: don't panic when transpose produces empty result 2019-11-08 09:40:39 -08:00