terraform-provider-stackitp.../docs/data-sources/server.md
Alexander Dahmen 68859a3fad
fix(server): Handle boot bolume correctly (#749)
* fix(server): Handle boot bolume correctly

- Display id and delete_on_termination in datasource
- Handle id and delete_on_termination in resource

Signed-off-by: Alexander Dahmen <alexander.dahmen@inovex.de>

* fixup

Signed-off-by: Alexander Dahmen <alexander.dahmen@inovex.de>

---------

Signed-off-by: Alexander Dahmen <alexander.dahmen@inovex.de>
2025-03-28 13:31:36 +01:00

46 lines
2 KiB
Markdown

---
# generated by https://github.com/hashicorp/terraform-plugin-docs
page_title: "stackit_server Data Source - stackit"
subcategory: ""
description: |-
Server datasource schema. Must have a region specified in the provider configuration.
---
# stackit_server (Data Source)
Server datasource schema. Must have a `region` specified in the provider configuration.
<!-- schema generated by tfplugindocs -->
## Schema
### Required
- `project_id` (String) STACKIT project ID to which the server is associated.
- `server_id` (String) The server ID.
### Read-Only
- `affinity_group` (String) The affinity group the server is assigned to.
- `availability_zone` (String) The availability zone of the server.
- `boot_volume` (Attributes) The boot volume for the server (see [below for nested schema](#nestedatt--boot_volume))
- `created_at` (String) Date-time when the server was created
- `id` (String) Terraform's internal resource ID. It is structured as "`project_id`,`server_id`".
- `image_id` (String) The image ID to be used for an ephemeral disk on the server.
- `keypair_name` (String) The name of the keypair used during server creation.
- `labels` (Map of String) Labels are key-value string pairs which can be attached to a resource container
- `launched_at` (String) Date-time when the server was launched
- `machine_type` (String) Name of the type of the machine for the server. Possible values are documented in [Virtual machine flavors](https://docs.stackit.cloud/stackit/en/virtual-machine-flavors-75137231.html)
- `name` (String) The name of the server.
- `network_interfaces` (List of String) The IDs of network interfaces which should be attached to the server. Updating it will recreate the server.
- `updated_at` (String) Date-time when the server was updated
- `user_data` (String) User data that is passed via cloud-init to the server.
<a id="nestedatt--boot_volume"></a>
### Nested Schema for `boot_volume`
Read-Only:
- `delete_on_termination` (Boolean) Delete the volume during the termination of the server.
- `id` (String) The ID of the boot volume