Find an image ID
Last updated on
To create a server with the STACKIT CLI, the IaaS API, or Terraform, you need the ID of the image to boot from. Use the latest version of an image whenever possible: it includes the most recent security patches and package updates. For how STACKIT names, releases, and retains images, see Operating system images.
Prerequisites
Section titled “Prerequisites”- You have installed the STACKIT CLI and logged in with
stackit auth login. - You know the ID of your STACKIT project.
- To run the commands in Bash, you have installed jq. PowerShell needs no additional tools.
Image names
Section titled “Image names”The name of an image tells you whether it is the latest version:
- The latest version has the plain operating system name, for example
Ubuntu 24.04orWindows Server 2025 Standard. - Older versions carry their release date in the name, for example
Ubuntu 24.04 2026-09-28orWindows Server 2025 Standard - 2026-10-14. - Images for the ARM64 architecture have
ARM64after the version, for exampleUbuntu 24.04 ARM64.
By default, the image list contains only the latest version of each image. To include older versions, use the --all flag in the STACKIT CLI or the all=true parameter in the IaaS API.
To filter the list, the commands on this page match the image name against a regular expression. The $ at the end matches only the plain name, that is, the latest version. The following patterns are examples:
^Ubuntu 24.04$finds the latest Ubuntu 24.04 image for x86.^Ubuntu 24.04 ARM64$finds the latest Ubuntu 24.04 image for ARM64.^Windows Server (2016|2019|2022|2025) Standard$finds the latest image of each Windows Server version.^Red Hat Enterprise Linux 9$finds the latest Red Hat Enterprise Linux 9 image. The$excludes the images for minor releases, such asRed Hat Enterprise Linux 9.4.
Find the latest image
Section titled “Find the latest image”-
Set the pattern for the image you need and list the matching images.
In Bash:
Terminal window PATTERN='^Windows Server (2016|2019|2022|2025) Standard$'stackit image list --project-id <PROJECT_ID> --output-format json \| jq --arg p "$PATTERN" '.[] | select(.name | test($p)) | {id, name, status, scope}'In PowerShell:
Terminal window $Pattern = '^Windows Server (2016|2019|2022|2025) Standard$'(stackit image list --project-id <PROJECT_ID> --output-format json | ConvertFrom-Json) |Where-Object { $_.name -match $Pattern } |Select-Object id, name, status, scope -
Note the value of
idfor the image you need. -
Optional: To check the details of the image, run the following command:
Terminal window stackit image describe <IMAGE_ID> --project-id <PROJECT_ID>
-
Set the pattern for the image you need and send a request to the
ListImagesendpoint of the IaaS API. Replaceeu01witheu02for region EU02.In Bash:
Terminal window PATTERN='^Windows Server (2016|2019|2022|2025) Standard$'stackit curl "https://iaas.api.stackit.cloud/v2/projects/<PROJECT_ID>/regions/eu01/images" \| jq --arg p "$PATTERN" '.items[] | select(.name | test($p)) | {id, name, status, scope}'In PowerShell:
Terminal window $Pattern = '^Windows Server (2016|2019|2022|2025) Standard$'stackit curl "https://iaas.api.stackit.cloud/v2/projects/<PROJECT_ID>/regions/eu01/images" |ConvertFrom-Json | Select-Object -ExpandProperty items |Where-Object { $_.name -match $Pattern } |Select-Object id, name, status, scope -
Note the value of
idfor the image you need.
Find an older image version
Section titled “Find an older image version”To list all versions of an image, remove the $ from the end of the pattern and include older versions. The commands sort the versions by creation date, with the latest version last.
-
Set the pattern for the image you need and list all matching versions.
In Bash:
Terminal window PATTERN='^Windows Server 2025 Standard'stackit image list --all --project-id <PROJECT_ID> --output-format json \| jq --arg p "$PATTERN" '[.[] | select(.name | test($p))] | sort_by(.createdAt) | .[] | {id, name, createdAt}'In PowerShell:
Terminal window $Pattern = '^Windows Server 2025 Standard'(stackit image list --all --project-id <PROJECT_ID> --output-format json | ConvertFrom-Json) |Where-Object { $_.name -match $Pattern } |Sort-Object createdAt |Select-Object id, name, createdAt -
Note the value of
idfor the version you need.
-
Set the pattern for the image you need and send a request with the
all=trueparameter. Replaceeu01witheu02for region EU02.In Bash:
Terminal window PATTERN='^Windows Server 2025 Standard'stackit curl "https://iaas.api.stackit.cloud/v2/projects/<PROJECT_ID>/regions/eu01/images?all=true" \| jq --arg p "$PATTERN" '[.items[] | select(.name | test($p))] | sort_by(.createdAt) | .[] | {id, name, createdAt}'In PowerShell:
Terminal window $Pattern = '^Windows Server 2025 Standard'stackit curl "https://iaas.api.stackit.cloud/v2/projects/<PROJECT_ID>/regions/eu01/images?all=true" |ConvertFrom-Json | Select-Object -ExpandProperty items |Where-Object { $_.name -match $Pattern } |Sort-Object createdAt |Select-Object id, name, createdAt -
Note the value of
idfor the version you need.