terraform
terraform import throws “Index value required” error for a string key value
As suggested by @JamesK in this answer above is only the solution if you are using Linux or more specifically bash or Git Bash under Windows. The solution for PowerShell is the following: terraform import resource[\`”prod-service-reports.audit\`”] … Thanks to the answer here 🙂
Referring to resources named with variables in Terraform
I was fundamentally misunderstanding how modules worked. Terraform does not support interpolation in resource names (see the relevant issues), but that doesn’t matter in my case, because the resources of each instance of a module are in the instance’s namespace. I was worried about resource names colliding, but the module system already handles that.
How to apply SQL Scripts on RDS with Terraform
Like this solution, You can also avoid instance setup time/cost by using your own machine with local-exec IF your RDS database is publicly available and you have setup ingress to allow your machine to connect. Then, with credentials stored securely in your environment, you would just do something like: resource “null_resource” “db_setup” { # runs … Read more
How can I convert a list to a string in Terraform?
Conversion from list to string always requires an explicit decision about how the result will be formatted: which character (if any) will delimit the individual items, which delimiters (if any) will mark each item, which markers will be included at the start and end (if any) to explicitly mark the result as a list. The … Read more