Skip to content

[FEATURE] Get access to stack metadata from a bundle #2361

@Wihrt

Description

@Wihrt

Is your feature request related to a problem? Please describe.

Currently, of you want to pass values between stacks, you have multiple option, but none of them works really good with bundles :

  • Using terraform_remote_state, but how to get the backend path if you are using stack_id ?
  • Using sharing_backend feature, but in order to be precise, you need to pass the stack_id somehow
  • There is no link between Bundles and Templates. Except through Components.
  • Bundles cannot generate globals in the stack
  • Bundles exports can not access to the terraform state or outputs values (and it's okay).

Describe the solution you'd like
I would like inside the bundle to have access to the stack(s) metadata

{
      "alias" = "foo"
      "class" = "whatever"
      "uuid" = "2101e0e5-90e0-4221-a868-416d14b92ee1"
      // Other bundle informations removed for clarity
      "stacks" = [
        "stack1" {
          id = "uuidv4"
          // Other stack metadata
        }
      ]
    }

Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.

I have found workaround to make it work, but there are painful, and not really usable in the long term.
I will add what I have got right now to make it work.

Additional context
Add any other context or screenshots about the feature request here.

No more context

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions