Skip to content

Commit

Permalink
chore(docs): Brief reference for local provider usage
Browse files Browse the repository at this point in the history
  • Loading branch information
skorfmann authored and DanielMSchmidt committed Aug 6, 2021
1 parent c209fe9 commit 70ca572
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions docs/working-with-cdk-for-terraform/using-providers.md
Original file line number Diff line number Diff line change
Expand Up @@ -211,3 +211,12 @@ When using the `cdktf` cli commands, it'll automatically set the process env `TF
Last but not least, when using multiple stacks within one application, provider caching is a basic prerequisite.

This behaviour can be disabled by setting `CDKTF_DISABLE_PLUGIN_CACHE_ENV` to non null value, e.g. `CDKTF_DISABLE_PLUGIN_CACHE_ENV=1`. This might be desired, when a different cache directory is configured via a `.terraformrc` configuration file.

## Using a Local Provider

Terraform supports using local providers. For CDK for Terrform being able to generate the type bindings from these providers, Terraform itself has to find these providers. There are two ways to achieve this:

- [Implied Local Mirrors](https://www.terraform.io/docs/cli/config/config-file.html#implied-local-mirror-directories)
- [Development Overrides](https://www.terraform.io/docs/cli/config/config-file.html#development-overrides-for-provider-developers)

Once configured properly, these providers can be referenced in the `cdktf.json` config file as any other provider in the Terraform registry.

0 comments on commit 70ca572

Please sign in to comment.