releases.shpreview
HashiCorp/CDK for Terraform

CDK for Terraform

$npx -y @buildinternet/releases show cdk-for-terraform
Mon
Wed
Fri
AprMayJunJulAugSepOctNovDecJanFebMarApr
Less
More
Releases2Avg0/wkVersionsv0.20.12 → v0.21.0
Oct 18, 2022

feat

  • feat(cli): Add support for terraform's parallelism flag #2107
  • feat: add redirect link to pre-built providers json file #2180
  • feat(cli): link to troubleshooting page for error #2192

fix

  • fix(provider-generator): change Static resource class to StaticResource as their namespace 'static' is not valid in TypeScript re-exports #2168
  • fix(cli): dont wrap list terminal output #2188
  • fix(cli): handle missing package versions for non-npm packages #2177
  • fix(docs): Fix upgrade guide imports for Python #2171
  • fix(docs): update old config key #2195

chore

  • chore: Update link to blogpost #2176
Oct 3, 2022

Breaking Changes Abbreviated version below, for a guide see Upgrade Guide for 0.13.

0.13 includes performance improvements to generated providers. Instead of exporting a flat list of exports including all supported resources and data sources, we now export each construct and it's associated structures in their own namespace. Due to this, the way you import constructs from your CDKTF application will change. For more information regarding this release, and some of the reasonings behind the changes, please check out the version 0.13 release post.

Typescript

// Before version 0.13
import { Container, Image, DockerProvider } from "@ckdtf/provider-docker";

// Version 0.13
import { Image } from "@cdktf/provider-docker/lib/image";
import { DockerProvider } from "@cdktf/provider-docker/lib/provider";
import { Container } from "@cdktf/provider-docker/lib/container";

Python

from cdktf_cdktf_provider_kubernetes.kubernetes import Namespace, Service, Deployment, KubernetesProvider
Sep 29, 2022

Breaking Changes

A very minor change in the UX of the cdktf get command now generates the provider bindings for all languages (except TypeScript) in parallel. This speeds up the process in general, but on devices with limited memory it could lead to Out of Memory errors. If this happens you can limit the parallelism by providing the parallelism flag: cdktf get --parallelism=1.

fix

  • fix(provider-generator): Add special case in case resource is named 'object' #2138
  • fix(docs): Fix two small bugs in the code causing it to not compile #2128
  • fix(lib): Add missing config options for AzurermBackend #2127
  • fix(cli): Update require package in template #2118
  • fix: Change url of pipenv in log #2117
  • fix(cli): support using remote execution in Terraform Cloud with up to 500 MB (instead of 10MB) #2108
  • fix(docs): remove empty code block #2102
  • fix: update constructs and go runtime versions #2096
  • fix(cli): add sentry DSN in build process #2085
  • fix(docs): fix wrong command mentioned in TFC docs #2083
  • fix: let create changelog script use commit hashes from PRs instead of finding merge commit messages that may not always exist #2068

feat

  • feat(cli): include language used in cdktf init telemetry event #2123
  • feat(cli): support generating provider bindings in parallel #2111

chore

  • chore(cli): Use the npm package's repository field for generating go package name #2145
  • chore: npm-check-updates && yarn upgrade #2142
  • chore: split up unit tests per package #2122
  • chore: Update diagram with new provider count #2104
  • chore: change YT link to cut version #2103
  • chore(cli): Don't trim output for unstructured logs #2100
  • chore: only run expensive tasks on source code changes #2099
  • chore: Support building with Go 1.19 #2098
  • chore: fix go azure example #2092
  • chore: fix the project board TS errors #2091
  • chore: npm-check-updates && yarn upgrade #2090
  • chore: npm-check-updates && yarn upgrade #2077
  • chore(examples): clean up examples #2069
  • chore(docs): Check whether links work :) #2063
  • chore: ensure we have license header #1960
  • chore: measure and print memory consumption of build and synth steps for examples in CI #2060
  • chore: start running tests against TF 1.2.8 and drop running against 1.0.7 #2058
Aug 26, 2022

Breaking Changes

A very minor change in the interface names for provisioners occured to support them in JSII languages, renaming the following interfaces:

  • ISSHProvisionerConnection to SSHProvisionerConnection
  • IWinrmProvisionerConnection to WinrmProvisionerConnection
  • IFileProvisioner to FileProvisioner
  • ILocalExecProvisioner to LocalExecProvisioner
  • IRemoteExecProvisioner to RemoteExecProvisioner

Another very minor change is that we now use the CloudBackend by default when running cdktf init. This requires Terraform >=1.1, therefore an error is thrown on cdktf init if you want to use Terraform Cloud and are on an older version. Already existing projects are not affected and you can use cdktf init --local and configure the RemoteBackend if you need to use an older version.

feat

  • feat(cli): throw an error if a user tries to create a new project with TFC on an old TF version #2062
  • feat: install time tool in Docker container to be able to use it for memory consumption tracking in tests #2059
  • feat: add Go port of TypeScript Google CloudRun example #2035
  • feat(lib): add support for cloud backend #1924

fix

  • fix(provider-generator): use terraform get instead of init to download modules #2057
  • fix(lib): Add missing config options for S3Backend: skipRegionValidation, assumeRolePolicyArns, assumeRoleTags, and assumeRoleTransitiveTagKeys #2050
  • fix: support provisioners in JSII languages #2042
  • fix(hcl2json): add fs-extra to dependencies #2040
  • fix(lib): Improve error message when provider constructs are missing #2039
  • fix(cli): Make provider add command case insensitive for provider names #2038
  • fix(cli): run a speculative plan on diff #2033

chore

  • chore(cli): remove red and magenta from colors for stack names #2064
  • chore: add link to hybrid module talk #2054
  • chore: make Terraform 1.2.8 available in Docker image #2051
  • chore: document updating the API documentation #2046
  • chore(docs): Remove positional language + fix style nits #2045
  • chore(lib): deprecate Resource in favor of Construct #2044
  • chore: update links in our youtube playlist examples #2043
  • chore: npm-check-updates && yarn upgrade #2025
  • chore: translate parts of the documentation #2011

refactor

  • refactor: port example script to JS #2047
Aug 18, 2022

fix

  • fix(cli): add major versions greater 1 to package name when installing pre-built providers for go #2002
  • fix(cli): Wait for other stacks to complete if one of them failed #1987
  • fix(cli): fix version detection for Java being a bit too optimistic about the package name #1995
  • fix(cli): Improve wording around starting from an existing Terraform project #1985
  • fix(tests): force local as Go now has pre-built providers #2005
  • fix(tests): as predicted, the test needs to be skipped for a bit of time #2004
  • fix(docs): fix aspects example not being valid TypeScript #1986
  • fix(docs): fix links by removing all links to the providers-and-resources page that does not exist anymore #2010
  • fix: don't lock state in tests #1990
  • fix: don't overwrite all NODE_OPTIONS #2009

chore

  • chore: add vercel config for cdk.tf redirects page #2016
  • chore: add notes for how to clean the local dotnet cache #2022
  • chore: add issue template for filing bugs with a pre-built providers label #1983
  • chore: npm-check-updates && yarn upgrade #1984
  • chore: npm-check-updates && yarn upgrade #2007
Jul 26, 2022

Breaking Changes

cdktf get exits with 0 exit code when no provider / module specifications are found in the cdktf.json

Previously we would throw an error and exit with 1 if there were no provider or module specifications in the cdktf.json file. This can be inconvenient if cdktf get is part of a workflow.

Fn.merge is split into Fn.mergeLists and Fn.mergeMaps

The Terraform merge function can merge both lists and maps, but this can cause issues when using the result in a typed language. Therefore we split it into Fn.mergeLists and Fn.mergeMaps, this means you need to change your cdktf programs code.

Simplified interfaces of recursive attributes

The generated provider bindings are based on the Terraform schema which does not support recursion and hence uses a large, explicit structure instead. Previously this resulted in long names such as e.g. Wafv2WebAclRuleStatementAndStatementStatementOrStatementStatementLabelMatchStatement. In 0.12 we implemented a first rough detection for this underlying recursion which drastically reduced the amount of generated interfaces as they now are converted to recursive data structures themselves. If you are currently using those types e.g. in a language like Java, you will need to change them to the new shorter names.

feat

  • feat(lib): Introduce Iterator and for_each to implement apply time iteration #1830
  • feat(lib): Introduce TerraformDynamicBlock to enable iterator usage on blocks #1882
  • feat(cli): support refresh only option for diff and deploy #1851
  • feat(docs): Add iterator docs page #1840
  • feat(docs): document FORCE_COLOR env var that allows disabling colored output #1917
  • feat(cli): plug provider add command in help printed after initializing a new cdktf project #1833
  • feat(lib): exposed testing matchers for other languages properly #1935

fix

  • fix: Allow "all" as ignoreChanges lifecycle value #1848
  • fix: Fixed naming collision between resources of different providers #1870
  • fix: Small fix to the CONTRIBUTING.md #1887
  • fix(cli): increase default max memory for node process when running app command for synth #1915
  • fix(provider-generator): Meta arguments available for generated modules #1880
  • fix(provider-generator): replace dashes with underscores in module names for Go when generating bindings for Terraform modules #1928
  • fix(hcl2json): bundle wasm_exec used for building Go instead of looking for it at runtime #1954
  • fix(hcl2cdk): use the same attribute renaming function as in the provider generation #1842
  • fix(hcl2cdk): maps should not be wrapped in arrays #1838

chore

  • chore: document CI flag #1888
  • chore: modernize example output #1914
  • chore: pin provider version #1896
  • chore: update prerequisites #1894
  • chore(tests): Re-enable Windows Provider Add C# Test #1879
  • chore: add tfe test as pre-step to releasing #1872
  • chore: split provider tests into one test per provider #1862
  • chore: reuse integration test definition for releases #1859
  • chore: fix broken link in readme #1845
  • chore: npm-check-updates && yarn upgrade #1706
Jun 8, 2022

feat

  • feat(cli): support custom Terraform Enterprise instances #1857
  • feat(hcl2json): expose hcl expression parser #1794

chore

  • chore: synthesize all boolean as iresolvable tests #1849
  • chore(docs): Fix Environment Variables and Best Practices #1839
Jun 2, 2022

fix

  • fix(cli): Fix package version check on Windows #1831
  • fix(docs): fix code blocks in "create and deploy" documentation #1826
  • fix(release): update changelog #1824

chore

  • chore(cli): filter usage errors from error reporting #1828
  • chore: document debug command #1812
  • chore: add best practice page #1790
May 24, 2022

Breaking Changes

Abbreviated version below, for a guide see Upgrade Guide for 0.11

TF_VAR_ prefixed environment variables can no longer be accessed at synth time

These environment variables will now be filtered out in the synth phase since they are only intended to be used during diff (plan) and deploy (apply) phases to supply values for TerraformVariables. This inhibits accidentally inlining those values into the generated cdk.tf.json config.

Environment variable and CLI option changes

  • DEBUG is replaced by setting CDKTF_LOG_LEVEL=debug, setting the CDKTF_LOG_LEVEL to debug will now also behave like DEBUG=1 and include logs from the provider generation
  • CDKTF_DISABLE_LOGGING=false is replaced by setting CDKTF_LOG_FILE_DIRECTORY=/path/to/logs/directory. If left empty no logs will be written.
  • --disable-logging was removed, instead use the environment variable CDKTF_LOG_LEVEL=off
  • DISABLE_VERSION_CHECK, CDKTF_DISABLE_PLUGIN_CACHE_ENV need to be set to true or 1, before anything worked.

Stack ids can no longer contain whitespaces

A TerraformStack may no longer contain whitespace characters, since we rely on paths being whitespace free. If you have a stack with an id containing a whitespace, please replace it with a hyphen. If the stack was already deployed with the default LocalBackend you might need to rename your statefile to match the new stack id.

Computed Map References are referenced through getter

For computed maps, the reference is now through a getter.

To access { property = "value" }, instead of resource.mapAttribute("property") you can now use resource.mapAttribute.lookup("property").

Use ComplexLists and ComplexMaps for complex assignable properties #1725

Assignable properties of the form Object[] or { [key: string]: Object } no longer have setters; they instead have putX methods. The getter return type is also changed to be a derivative of either ComplexList or ComplexMap.

fix

  • fix(docs): Make sure code example works #1807
  • fix(lib): Delay complex object fqn so that override id can still be used #1793
  • fix(provider-generator): strictly adhere to the provider schema #1792
  • fix: Avoid unstable fqn for TerraformElements #1779
  • fix(cli): Respect CDKTF_HOME environment variable for checkpoint telemetry #1778
  • fix(docs): remove outdated docs from the previous watch implementation #1768
  • fix(cli): throw an error if a stack contains a whitespace #1750

feat

  • feat(lib): add docstrings to gcs/http/local backend resources #1803
  • feat(lib): add a warning about id fields #1802
  • feat(docs): add guidance around secrets and warn that those values might be inlined in the generated Terraform config #1801
  • feat(lib): add docstrings to cos/etcd/etcdv3 backend resources #1783
  • feat(lib): add docstrings to artifactory/azurerm/consul backend resources #1781
  • feat(lib): add docstrings to S3 backend resource #1780
  • feat(release): support running releases on backport-release branches besides only on main #1770
  • feat(cli): add cdktf provider add command #1761
  • feat(provider-generator): Use ComplexList for any complex list #1725

test

  • test(lib): ensure list mapper does not fail when passed IResolvables #1791

chore

  • chore: group needs to be prefixed per type #1813
  • chore: limit CI concurrency to the latest pushed commits #1810
  • chore(cli): add sentry error reporting #1809
  • chore: document computed map reference documentation #1775
  • chore(release): Update changelog to contain backported release for 0.10.4 #1773
  • chore(docs): document how to debug cdktf programs #1758
May 4, 2022

fix

  • fix(cli): Stop pinning jest in TS init template #1769
Apr 28, 2022

feat

  • feat(provider-generator): emit a versions.json file to the output directory, containing the used provider versions #1749
  • feat(cli): debug command #1731

chore

  • chore(cli): add environment variable to disable version checks #1757
  • chore: drop Terraform v0.15.7 from Docker image and replace with v1.1.9 for running tests #1747
  • chore: add Terraform v1.1.9 to Docker image #1743
  • chore(docs): update env var usage #1693

fix

  • fix(lib): Add new optional AWS route attributes #1755
  • fix(cli): handle version check more defensively #1753
  • fix(cli): we should not send wait for approval if a stop has been issued #1740
  • fix(cli): Fix indentation of RemoteBackend in CSharp and Java template #1733
  • fix(cli): fix templates to properly indent cdktf.json and add RemoteBackend in TS template #1732
Apr 19, 2022

fix

  • fix(tests): pin awscc version #1727
  • fix(cli): return non-zero exit code in case of error when using cdktf diff #1726
  • fix(cli): allow init command to run in a directory containing a README.md #1722
  • fix(provider-generator): Include "arn" when assignable #1716
  • fix(hcl2cdk): detect list extensions in strings and wrap them in an array #1707
  • fix(lib): override values containing intrinsic tokens caused an infinite loop #1702
  • fix(lib): contextualize error messages in terraform functions #1699
  • fix(cli): fix path for .terraform directory #1694
  • fix(cli): improve cli error handling #1687

chore

  • chore: align versions to an unpublished version #1718
  • chore(docs): update convert docs #1701
  • chore(docs): update aspect docs #1690
  • chore: npm-check-updates && yarn upgrade #1683

test

  • test(hcl2cdk): add test case for property renaming #1709

feat

  • feat(cli): warn users about misaligned CLI and library versions #1700
  • feat(lib): improve error messages around misused list mutation #1691
Apr 1, 2022

fix

  • fix(cli): fix convert single blocks as array bug #1680
  • fix(cli): Only print error that's thrown #1678

refactor

  • refactor(tests): move from table driven tests to functional way #1679
  • refactor(cli): remove xstate as state machine #1670

chore

  • chore(docs): update project maturity statement #1676
  • chore(docs): add sidebar link #1674
  • chore: add extra column for PRs outside our main repo #1673

feat

  • feat(cli): support HTTP_PROXY for Terraform Cloud #1507
Mar 30, 2022

Breaking Changes

Remove cdktf synth --json Option #1640

If you are using cdktf synth --json <stack-name> to get the synthesized JSON configuration for your Stack, you will now need to run cdktf synth && cat ./cdktf.out/stacks/<stack-name>/cdk.tf.json instead. The ./cdktf.out part is your output directory (set by cdktf.json or via the --output flag).

Model ComplexComputedLists as ComplexLists and ComputedObjects #1499

In an effort to streamline the interfaces of resources, computed attributes of the type list and set are now modeled as a separate ComplexList type instead of being a method that directly takes an index and returns an item. This change also did change the type of the index from string to number.

Typescript

// previously
const firstItemId = resource.listAttribute("0").id;

// new
const firstItemId = resource.listAttribute.get(0).id;
const firstItem = resource.listAttribute.get(0); // now possible

Python

first_item_id = resource.list_attribute("0").id;
Feb 24, 2022

fix

  • fix(lib): check for null objects and don't try to reverse undefined or null #1592

chore

  • chore(cli): fix typo in test assertion #1591

feat

  • feat(examples): Add Scaleway Golang example #1576

fix

  • fix(cli): convert failed with a single provider passed #1588
  • fix(tests): Windows needs special docker host override to work #1567
Feb 21, 2022

fix

  • fix: cross-stack references in terraform cloud remote execution mode #1574

chore

  • chore: npm-check-updates && yarn upgrade #1579
  • chore: npm-check-updates && yarn upgrade #1565
Feb 16, 2022

feat

  • feat(cli): show help when no command is passed #1540

fix

  • fix(tests): run package before running unit tests in release pipelines #1563
  • fix(hcl2cdk): handle no providers passed and add cdktf import for remote state data sources #1561
  • fix(cli): Fix template for Go not adding jsii import when using Terraform Cloud #1556
  • fix(lib): Add missing regex Function #1531
  • fix(cli): add better messaging on inint #1524
  • fix(docs): fix a typo in serverless-application-typescript.md #1517
  • fix(provider-generator): Replace jsii incompatible names #1516
  • fix(provider-generator): don't build generated edge provider output as part of building the provider-generator #1509
  • fix(tests): add --ci flag to jest invocations when in CI #1498
  • fix: stringValue rated valid strings as unescaped double quotes #1566
  • chore(deps): upgrade jsii (substantially improves cdktf get performance for Go) #1558
  • fix(cli): reflect correct node version requirement #1573

chore

  • chore(docs): we now support cross stack refs, the section is no longer needed #1571
  • chore(docs): remove old docs files #1542
  • chore(docs): Update main from stable-website #1529
  • chore(docs): remove old layouts folder #1522
  • chore(docs): Merge stable-website into main #1515
  • chore(docs): add 0.9 upgrade guide #1512

test

  • test(hcl2cdk): check if produced code can generate HCL #1539
Jan 26, 2022

Breaking Changes

Standardize IResolvable Usage #1299

This is an effort to make sure attributes can be freely passed between resources for all different types.

There is a minor breaking change:

  • count on resources and data sources has gone from number | cdktf.IResolvable to number. If code was previously passing an IResolvable, it will now need to use Token.asNumber()

Map Tokens #1411

As part of an effort to use more native types, there are now tokens for maps of primitive values.

As a result, there is a minor breaking change:

  • Map attributes have gone from { [key: string]: TYPE } | cdktf.IResolvable to { [key: string]:TYPE } when TYPE is string, number, or boolean.
    • The most common impact is maps created by using Terraform functions (Fn.(...)) will now need to be passed to Token.as<String/Number/Boolean>Map() before assigning to a resource attribute.

Number[] Tokens #1471

As part of an effort to use more native types, there are now tokens for number[]. This is mostly an internal change, but there is now Token.asNumberList() which can be used to convert other values into number[].

As a result of some standardization, there is a minor breaking change:

  • Boolean[] attributes have gone from boolean[] to Array<boolean | IResolvable> | IResolvable.
    • This is done because neither boolean or boolean[] is representable by a token.
    • This should make it easier to pass around boolean[] between resources and fuctions.
    • For jsii languages (especially Java and C#), these types will end up as List<Object>.

feat

  • feat(cli): output command #1495
  • feat(lib): cross-stack references #1416
  • feat(lib): cross stack references other backends #1488
  • feat(lib): Allow relative assets #1346
  • feat(lib): Create assets for local modules #1476
  • feat(lib): number[] Tokens #1471
  • feat(lib): produce stable cdk.tf.json output #1454
  • feat(lib): Initial improvements for set support #1415
  • feat(lib): Map Tokens #1411
  • feat(provider-generator): reference computed values nested in lists #1468
  • feat(tests): add test which confirms that modules now support sets #1497

fix

  • fix(cli): speed up shell autocompletions #1496
  • fix(cli): remove deprecated -state option #1461
  • fix(lib): resolve objects correctly in cross stack references #1487
  • fix(docs): fix typo #1387
  • fix: increase memory for integration:update command #1490

chore

  • chore(examples): Added go/azurerm examples #1275
  • chore(lib): Standardize IResolvable usage #1299
  • chore(docs): document pinning state to stack #1504
  • chore(docs): link to AWS Constructs base class #1473
  • chore(docs): Final Docs Migration Cleanup #1431
  • chore(docs): Manual windows testing #1407
  • chore: migrate docs to mdx #1421
  • chore: store website nav files #1434
  • chore: update example for azure app service #1484
  • chore: add tooling for an automated issue dashboard #1474
  • chore: decrease update speed of the project board #1485
  • chore: npm-check-updates && yarn upgrade #1477
  • chore: npm-check-updates && yarn upgrade #1489
  • chore: npm-check-updates && yarn upgrade #1503
  • chore: remove patch file created through update automation #1491
Jan 7, 2022

fix

  • fix(lib): don't treat strings as maps #1467
  • fix: update specified nodejs version to >=12.16 to reflect our actual requirements #1466

Other

  • chore: fix constructs error #1460
Latest
v0.21.0
Tracking Since
May 8, 2020
Last fetched Apr 18, 2026