Skip to content

Atmos 1.194.0 breaks component resolution when metadata.component is omitted, incorrectly using inherited component name #1609

@RoseSecurity

Description

@RoseSecurity

Describe the Bug

After upgrading to Atmos 1.194.0, we are encountering an TF operation error on a component that previously worked with 1.193.0:

atmos tf plan eks/n8n -s <stack>

 Error

 invalid Terraform component: 'eks/n8n' points to the Terraform component 'helm-teleport-helper', but it does not exist in '/workspace/components/terraform'

If no metadata.component is set, it uses the inherited component:

components:
  terraform:
    eks/n8n:
      metadata:
        inherits:
          - "eks/helm-teleport-helper"
      settings:
        spacelift:
          workspace_enabled: true
          space_name_template: "{namespace}-plat"

The following configuration works:

components:
  terraform:
    eks/n8n:
      metadata:
        inherits:
          - "eks/helm-teleport-helper"
        component: eks/n8n
      settings:
        spacelift:
          workspace_enabled: true
          space_name_template: "{namespace}-plat"

If the metadata.component is excluded, the component fails

Expected Behavior

  • This component previously functioned in version 1.193.0, enabling complete Terraform operations.

Steps to Reproduce

# Stacks validate
atmos validate stacks
INFO All stacks validated successfully

# Component validates
atmos validate component eks/n8n -s <stack>
INFO Validated successfully component=eks/n8n stack=<stack>

# TF Plan
atmos tf plan eks/n8n -s <stack>

 Error

 invalid Terraform component: 'eks/n8n' points to the Terraform component 'helm-teleport-helper', but it does not exist in '/workspace/components/terraform'

Screenshots

No response

Environment

  • OS: Debian GNU/Linux 12 (bookworm)
  • Atmos Version: 1.194.0

Additional Context

Describe Component

atmos describe component eks/n8n -s <stack> --query .vars
name: n8n
tags:
  application: n8n
  atmos_component: eks_n8n
  role: admin
  team: platform
  terraform_component: eks_helm-teleport-helper
....

Metadata

Metadata

Assignees

No one assigned

    Labels

    bug🐛 An issue with the system

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions