Questions tagged [hcl]

HashiCorp Configuration Language. The structured configuration syntax that serves as the basis for Terraform's configuration language.

HCL establishes the syntax Terraform uses for things like arguments, blocks, literal values, and expressions. But what most people think of as the Terraform language extends beyond just the syntax; the built-in functions, Terraform-specific block types (like resource and variable), and Terraform-specific named values available in expressions are all implementation details of Terraform itself.

Source: https://www.terraform.io/docs/glossary.html#hcl

291 questions
0
votes
2 answers

HCL Domino AppDevPack - writeAttachments

The new V1.0.2 has new capabilities to upload attachments to a domino document. My upload code is successful as long a I use files <= 48KB. As soon as I try to upload a larger file, the upload takes place, in the domino document I find an attachment…
0
votes
0 answers

Terraform - Protocol error when using Heredoc in local-exec provisioner

I'm using a heredoc to allow for multiple lines in a Terraform local-exec provisioner. For some reason when I use > to create a new file I'm getting a Protocal error. I've tried wrapping it with single/double qoutes, but that did not work. However…
navig8tr
  • 1,724
  • 8
  • 31
  • 69
0
votes
1 answer

Parse value as int in HLC files

I am writing the template for a parametrized HashiCorp Nomad job. One of its parameters is priority, which is supposed to be an integer between 0 and 100. Like other tools, Nomad supports variable interpolation, so that a variable can be defined at…
Alexander George
  • 871
  • 9
  • 22
0
votes
1 answer

Problem with upload a azurerm_storage_blob because the azurerm_storage_container exists

i want to upload a generated file as new blobobject to azure. My problem is, that if the azurerm_storage_container doesn't exists i have to create it as a resource. But if this container is already present in the storage account i get the error…
user11374059
0
votes
2 answers

Terraform interpolation 0.12

According to this: https://www.hashicorp.com/blog/terraform-0-12-template-syntax Terraform is extending interpolation syntax used for strings (${}) to loops and conditionals (which implies interpolation syntax is still valid for strings). However,…
Snowcrash
  • 80,579
  • 89
  • 266
  • 376
0
votes
1 answer

Terrafom 0.12.6 map variable with count interpolation

I am trying to attach a list of policy ARN that I've been created as a map list. Please see below: variables.tf: variable "arns_map" { type = "map" default = { default = [ "default" ] bakery = [ …
Rodrigo Andrade
  • 429
  • 4
  • 14
0
votes
1 answer

How to activate new v2 newsletter design in Connections CR5

We recently updated Connections CR4 to CR5. Before the update, the new newsletter design was enabled by setting notifications_v2 in the section of notification-config.xml file.…
Daniel
  • 968
  • 3
  • 13
  • 32
0
votes
1 answer

Can I have a namespace or hierarchy for resources in terraform? Or otherwise group resources together?

As a specefic example, I have a group of subnets that are all used for the same thing, but are spread across multiple availabililty zones. I'd like to be able to reference all of them as a list, so that I could do something like…
Thayne
  • 6,619
  • 2
  • 42
  • 67
0
votes
1 answer

Collection or Template in Terraform HCL

I'm trying to find directions on how to do a pretty simple thing in HCL. I have one block like this resource "aws_elastic_beanstalk_environment" "qa" { name "qa1" #insert settings here } And I want to insert a collection of…
4m1r
  • 12,234
  • 9
  • 46
  • 58
0
votes
1 answer

How to pre-check and set variable before compiling on Go?

I'm going to pre-check HCL contents and set it as a variable in golang. i.e. HCL contents should be parsed before compilation and set as a specific variable. Here is the example. . ├── config.mel └── main.go The config.mel has the following HCL…
cdevman
  • 119
  • 2
  • 14
0
votes
0 answers

Set HCL fields in golang

I'm going to set HCL fields in golang. Here the example. package main import ( "log" "os" "github.com/hashicorp/hcl" ) const ( EXAMPLE_HCL = `config = "/etc/test.conf"` ) type HCLConfig struct { ConfigFile string …
cdevman
  • 119
  • 2
  • 14
-1
votes
1 answer

Convert terraform array to string

I have a terraform array/list r53_zone_names = [ "google.com.", "example.com.", ] But I wish to convert it to sting for sending it to external-dns helm chart, it asks for such one: "{google.com.,example.com.}" How to do that with HCL?…
ipeacocks
  • 2,187
  • 3
  • 32
  • 47
-1
votes
1 answer

Terraform: Can I conditionally create an object within a map?

I have a module defined for an EKS cluster using hashicorp's AWS EKS module, and I am trying to conditionally create a managed node group depending on the cluster. I have no idea if this is even feasible, I know conditionals within Terraform are…
-1
votes
1 answer

Terraform: How to use each.value as variable name

Here is a resource block that uses for_each on a set of string names. Each resource ends up being an environment variable for this provider, including a key and value: resource "environments_variables_v1" "api_env_var" { service_sid =…
Jeremy Schultz
  • 579
  • 1
  • 6
  • 26
-1
votes
1 answer

How do I pass object(list) to string(list) - Terraform

I want to pass a list with 2 objects to lambda_name as an array variable, lambda_name must receive my_app and my_app_2 key name, example: variable "lambda" { type = object({ my_app = object({ name = string }) my_app_2 = object({ …
1 2 3
19
20