github.com/hashicorp/packer@v1.14.3/website/content/partials/from-1.5/locals/example-block.mdx (about)

     1  ```hcl
     2  # locals.pkr.hcl
     3  locals {
     4      # locals can be bare values like:
     5      wee = local.baz
     6      # locals can also be set with other variables :
     7      baz = "Foo is '${var.foo}' but not '${local.wee}'"
     8  }
     9  
    10  # Use the singular local block if you need to mark a local as sensitive
    11  local "mylocal" {
    12    expression = "${var.secret_api_key}"
    13    sensitive  = true
    14  }
    15  ```