Skip to content

Add a "json" type for set #1678

@dannystaple

Description

@dannystaple

Description

The set command https://registry.terraform.io/providers/hashicorp/helm/latest/docs/resources/release#set-6 will not handle JSON or some characters very well, resulting in parser issues. E.g. error parsing index: strconv.Atoi if there are square brackets anywhere.

The literal command can be used, but is a very blunt instrument, overriding whole structures.

However, a "set-json" would mean the keys can override nested structure elements, and with json. Json would not have it's "runes" interpreted as "stop" runes by the parser after the first = sign.

Potential Terraform Configuration

Within a resource "helm_release" "chartname":

set =   [
  {
    name = "somePod.annotations.interesting\\.annotation\\.for\\.some\\.operator",
    value = jsonencode("thing with runes parser might think are stops"),
    type="json"
  }
]

Community Note

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions