1. Registry
  2. Packages
  3. stackit
  4. API Docs
  5. getImages
Viewing docs for stackit v0.0.8
published on Friday, Oct 16, 2026 by stackitcloud
stackit logo
Viewing docs for stackit v0.0.8
published on Friday, Oct 16, 2026 by stackitcloud

    Lists all IaaS images in a project and region. Results are sorted by image ID.

    This datasource is in beta and may be subject to breaking changes in the future. Use with caution. See our guide for how to opt-in to use beta resources.

    Example Usage

    variable "project_id" {
      type = string
    }
    
    data "stackit_images" "all" {
      project_id = var.project_id
    }
    
    data "stackit_images" "filtered" {
      project_id = var.project_id
      filter = {
        label_selector = "linux="
      }
      timeouts = { read = "5m" }
    }
    
    output "image_ids" {
      value = [for image in data.stackit_images.all.results : image.image_id]
    }
    
    # These expressions filter locally in Terraform; they are not API filters.
    locals {
      exact_name     = [for image in data.stackit_images.all.results : image if image.name == "Ubuntu 22.04"]
      matching_names = [for image in data.stackit_images.all.results : image if can(regex("Ubuntu.*", image.name))]
      ubuntu_images  = [for image in data.stackit_images.all.results : image if try(image.config.operating_system_distro, "") == "ubuntu"]
    }
    

    Using getImages

    Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

    function getImages(args: GetImagesArgs, opts?: InvokeOptions): Promise<GetImagesResult>
    function getImagesOutput(args: GetImagesOutputArgs, opts?: InvokeOutputOptions): Output<GetImagesResult>
    def get_images(filter: Optional[GetImagesFilter] = None,
                   project_id: Optional[str] = None,
                   region: Optional[str] = None,
                   timeouts: Optional[GetImagesTimeouts] = None,
                   opts: Optional[InvokeOptions] = None) -> GetImagesResult
    def get_images_output(filter: pulumi.Input[Optional[GetImagesFilterArgs]] = None,
                   project_id: pulumi.Input[Optional[str]] = None,
                   region: pulumi.Input[Optional[str]] = None,
                   timeouts: pulumi.Input[Optional[GetImagesTimeoutsArgs]] = None,
                   opts: Optional[InvokeOutputOptions] = None) -> Output[GetImagesResult]
    func LookupImages(ctx *Context, args *LookupImagesArgs, opts ...InvokeOption) (*LookupImagesResult, error)
    func LookupImagesOutput(ctx *Context, args *LookupImagesOutputArgs, opts ...InvokeOption) LookupImagesResultOutput

    > Note: This function is named LookupImages in the Go SDK.

    public static class GetImages 
    {
        public static Task<GetImagesResult> InvokeAsync(GetImagesArgs args, InvokeOptions? opts = null)
        public static Output<GetImagesResult> Invoke(GetImagesInvokeArgs args, InvokeOptions? opts = null)
        public static Output<GetImagesResult> Invoke(GetImagesInvokeArgs args, InvokeOutputOptions opts)
    }
    public static CompletableFuture<GetImagesResult> getImages(GetImagesArgs args, InvokeOptions options)
    public static Output<GetImagesResult> getImages(GetImagesArgs args, InvokeOptions options)
    public static Output<GetImagesResult> getImages(GetImagesArgs args, InvokeOutputOptions options)
    
    fn::invoke:
      function: stackit:index/getImages:getImages
      arguments:
        # arguments dictionary
    data "stackit_get_images" "name" {
        # arguments
    }

    The following arguments are supported:

    ProjectId string
    STACKIT project ID.
    Filter GetImagesFilter
    API-side image filtering options.
    Region string
    Region override. Uses the provider region when omitted.
    Timeouts GetImagesTimeouts
    ProjectId string
    STACKIT project ID.
    Filter GetImagesFilter
    API-side image filtering options.
    Region string
    Region override. Uses the provider region when omitted.
    Timeouts GetImagesTimeouts
    project_id string
    STACKIT project ID.
    filter object
    API-side image filtering options.
    region string
    Region override. Uses the provider region when omitted.
    timeouts object
    projectId String
    STACKIT project ID.
    filter GetImagesFilter
    API-side image filtering options.
    region String
    Region override. Uses the provider region when omitted.
    timeouts GetImagesTimeouts
    projectId string
    STACKIT project ID.
    filter GetImagesFilter
    API-side image filtering options.
    region string
    Region override. Uses the provider region when omitted.
    timeouts GetImagesTimeouts
    project_id str
    STACKIT project ID.
    filter GetImagesFilter
    API-side image filtering options.
    region str
    Region override. Uses the provider region when omitted.
    timeouts GetImagesTimeouts
    projectId String
    STACKIT project ID.
    filter Property Map
    API-side image filtering options.
    region String
    Region override. Uses the provider region when omitted.
    timeouts Property Map

    getImages Result

    The following output properties are available:

    Id string
    Stable Terraform ID, structured as "projectId,region".
    ProjectId string
    STACKIT project ID.
    Results List<GetImagesResult>
    All matching images, sorted by imageId ascending.
    Filter GetImagesFilter
    API-side image filtering options.
    Region string
    Region override. Uses the provider region when omitted.
    Timeouts GetImagesTimeouts
    Id string
    Stable Terraform ID, structured as "projectId,region".
    ProjectId string
    STACKIT project ID.
    Results []GetImagesResult
    All matching images, sorted by imageId ascending.
    Filter GetImagesFilter
    API-side image filtering options.
    Region string
    Region override. Uses the provider region when omitted.
    Timeouts GetImagesTimeouts
    id string
    Stable Terraform ID, structured as "projectId,region".
    project_id string
    STACKIT project ID.
    results list(object)
    All matching images, sorted by imageId ascending.
    filter object
    API-side image filtering options.
    region string
    Region override. Uses the provider region when omitted.
    timeouts object
    id String
    Stable Terraform ID, structured as "projectId,region".
    projectId String
    STACKIT project ID.
    results List<GetImagesResult>
    All matching images, sorted by imageId ascending.
    filter GetImagesFilter
    API-side image filtering options.
    region String
    Region override. Uses the provider region when omitted.
    timeouts GetImagesTimeouts
    id string
    Stable Terraform ID, structured as "projectId,region".
    projectId string
    STACKIT project ID.
    results GetImagesResult[]
    All matching images, sorted by imageId ascending.
    filter GetImagesFilter
    API-side image filtering options.
    region string
    Region override. Uses the provider region when omitted.
    timeouts GetImagesTimeouts
    id str
    Stable Terraform ID, structured as "projectId,region".
    project_id str
    STACKIT project ID.
    results Sequence[GetImagesResult]
    All matching images, sorted by imageId ascending.
    filter GetImagesFilter
    API-side image filtering options.
    region str
    Region override. Uses the provider region when omitted.
    timeouts GetImagesTimeouts
    id String
    Stable Terraform ID, structured as "projectId,region".
    projectId String
    STACKIT project ID.
    results List<Property Map>
    All matching images, sorted by imageId ascending.
    filter Property Map
    API-side image filtering options.
    region String
    Region override. Uses the provider region when omitted.
    timeouts Property Map

    Supporting Types

    GetImagesFilter

    LabelSelector string
    Experimental: API label selector passed directly to the image-list endpoint.
    LabelSelector string
    Experimental: API label selector passed directly to the image-list endpoint.
    label_selector string
    Experimental: API label selector passed directly to the image-list endpoint.
    labelSelector String
    Experimental: API label selector passed directly to the image-list endpoint.
    labelSelector string
    Experimental: API label selector passed directly to the image-list endpoint.
    label_selector str
    Experimental: API label selector passed directly to the image-list endpoint.
    labelSelector String
    Experimental: API label selector passed directly to the image-list endpoint.

    GetImagesResult

    Checksum GetImagesResultChecksum
    Image checksum.
    Config GetImagesResultConfig
    Image hardware and operating-system configuration.
    DiskFormat string
    Image disk format.
    ImageId string
    Image ID.
    Labels Dictionary<string, string>
    Image labels.
    MinDiskSize int
    Minimum disk size in GB.
    MinRam int
    Minimum RAM in MB.
    Name string
    Image name.
    Protected bool
    Whether the image is protected.
    Scope string
    Image scope.
    Status string
    Image status.
    Checksum GetImagesResultChecksum
    Image checksum.
    Config GetImagesResultConfig
    Image hardware and operating-system configuration.
    DiskFormat string
    Image disk format.
    ImageId string
    Image ID.
    Labels map[string]string
    Image labels.
    MinDiskSize int
    Minimum disk size in GB.
    MinRam int
    Minimum RAM in MB.
    Name string
    Image name.
    Protected bool
    Whether the image is protected.
    Scope string
    Image scope.
    Status string
    Image status.
    checksum object
    Image checksum.
    config object
    Image hardware and operating-system configuration.
    disk_format string
    Image disk format.
    image_id string
    Image ID.
    labels map(string)
    Image labels.
    min_disk_size number
    Minimum disk size in GB.
    min_ram number
    Minimum RAM in MB.
    name string
    Image name.
    protected bool
    Whether the image is protected.
    scope string
    Image scope.
    status string
    Image status.
    checksum GetImagesResultChecksum
    Image checksum.
    config GetImagesResultConfig
    Image hardware and operating-system configuration.
    diskFormat String
    Image disk format.
    imageId String
    Image ID.
    labels Map<String,String>
    Image labels.
    minDiskSize Integer
    Minimum disk size in GB.
    minRam Integer
    Minimum RAM in MB.
    name String
    Image name.
    protected_ Boolean
    Whether the image is protected.
    scope String
    Image scope.
    status String
    Image status.
    checksum GetImagesResultChecksum
    Image checksum.
    config GetImagesResultConfig
    Image hardware and operating-system configuration.
    diskFormat string
    Image disk format.
    imageId string
    Image ID.
    labels {[key: string]: string}
    Image labels.
    minDiskSize number
    Minimum disk size in GB.
    minRam number
    Minimum RAM in MB.
    name string
    Image name.
    protected boolean
    Whether the image is protected.
    scope string
    Image scope.
    status string
    Image status.
    checksum GetImagesResultChecksum
    Image checksum.
    config GetImagesResultConfig
    Image hardware and operating-system configuration.
    disk_format str
    Image disk format.
    image_id str
    Image ID.
    labels Mapping[str, str]
    Image labels.
    min_disk_size int
    Minimum disk size in GB.
    min_ram int
    Minimum RAM in MB.
    name str
    Image name.
    protected bool
    Whether the image is protected.
    scope str
    Image scope.
    status str
    Image status.
    checksum Property Map
    Image checksum.
    config Property Map
    Image hardware and operating-system configuration.
    diskFormat String
    Image disk format.
    imageId String
    Image ID.
    labels Map<String>
    Image labels.
    minDiskSize Number
    Minimum disk size in GB.
    minRam Number
    Minimum RAM in MB.
    name String
    Image name.
    protected Boolean
    Whether the image is protected.
    scope String
    Image scope.
    status String
    Image status.

    GetImagesResultChecksum

    Algorithm string
    Digest string
    Algorithm string
    Digest string
    algorithm string
    digest string
    algorithm String
    digest String
    algorithm string
    digest string
    algorithm String
    digest String

    GetImagesResultConfig

    GetImagesTimeouts

    Read string
    A string that can be parsed as a duration consisting of numbers and unit suffixes, such as "30s" or "2h45m". Valid time units are "s" (seconds), "m" (minutes), "h" (hours).
    Read string
    A string that can be parsed as a duration consisting of numbers and unit suffixes, such as "30s" or "2h45m". Valid time units are "s" (seconds), "m" (minutes), "h" (hours).
    read string
    A string that can be parsed as a duration consisting of numbers and unit suffixes, such as "30s" or "2h45m". Valid time units are "s" (seconds), "m" (minutes), "h" (hours).
    read String
    A string that can be parsed as a duration consisting of numbers and unit suffixes, such as "30s" or "2h45m". Valid time units are "s" (seconds), "m" (minutes), "h" (hours).
    read string
    A string that can be parsed as a duration consisting of numbers and unit suffixes, such as "30s" or "2h45m". Valid time units are "s" (seconds), "m" (minutes), "h" (hours).
    read str
    A string that can be parsed as a duration consisting of numbers and unit suffixes, such as "30s" or "2h45m". Valid time units are "s" (seconds), "m" (minutes), "h" (hours).
    read String
    A string that can be parsed as a duration consisting of numbers and unit suffixes, such as "30s" or "2h45m". Valid time units are "s" (seconds), "m" (minutes), "h" (hours).

    Package Details

    Repository
    stackit stackitcloud/pulumi-stackit
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the stackit Terraform Provider.
    stackit logo
    Viewing docs for stackit v0.0.8
    published on Friday, Oct 16, 2026 by stackitcloud

      Try Pulumi Cloud free.
      Your team will thank you.

      Start free trial