Skip to content

interpolate variable with non-module HCL files #81

@talset

Description

@talset

Currently, variable interpolation works when the Terraform code is structured as module (like here

But the estimation will fail with a simple TF file such:

provider "aws" {
  region = "eu-west-1"
}

variable "front_ebs_optimized" {
  default = false
}

resource "aws_instance" "web" {
  ami           = data.aws_ami.ubuntu.id
  instance_type = "m3.xlarge"

  ebs_optimized = var.front_ebs_optimized
}

Because the variable is not replaced by the real value

expected

Implement the variable interpolation on non-module terraform code

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions