Skip to content

[Feature Request] Add data source to list all available images #1781

Description

@Manisha15

Problem description

I'm implementing a STACKIT compute resource integration for Foreman via foreman_opentofu . Foreman needs to discover all available images and present them to the user before provisioning.

Currently, stackit_image_v2 selects a single matching image, but there is no data source that returns the complete list of available images.

Proposed solution

Add a stackit_images data source that returns all images available to a project/region.

data "stackit_images" "available" {
  project_id = var.project_id
}

output "images" {
  value = data.stackit_images.available.images
}

Alternative solutions (optional)

The image list could be retrieved externally via the STACKIT API/CLI, but this requires additional logic outside Terraform/OpenTofu.

Additional information

Other compute resources supported by Foreman provide image enumeration, so having this capability would make the STACKIT integration consistent with them.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions