Problem description
We want to deploy a server via terraform with a bootstrap config, and therefore pass this config with the user_data argument. But this did not work, the config was not loaded during initial startup of the server. While troubleshooting, we noticed that there is the configDrive-Flag available in the API (API-DOCS), but not in the terraform provider. Leveraging this flag in an API-Call made the bootstrap config load during initial startup of the server
Proposed solution
We want to use the configDrive-Flag, which is available in the API, also in terraform, because we assume that this will resolve the bug with the bootstrap config not loading during initial startup, which was the case when we used the API directly.
resource "stackit_server" "server-1" {
project_id = stackit_resourcemanager_project.xyz.project_id
name = "vm-xyz-1"
boot_volume = {
source_type = "volume"
source_id = stackit_volume.server-1_volume.volume_id
}
availability_zone = "eu01-1"
machine_type = "s3i.16"
configDrive = true # -> this is currently not supported, just available via API
user_data = file("user-data.yaml")
network_interfaces = [
stackit_network_interface.nic-1.network_interface_id,
stackit_network_interface.nic-2.network_interface_id,
stackit_network_interface.nic-3.network_interface_id
]
lifecycle {
ignore_changes = [user_data]
}
}
Alternative solutions (optional)
A clear and concise description of any alternative solutions or features you've considered. (optional)
Additional information
Feel free to add any additional information here.
Problem description
We want to deploy a server via terraform with a bootstrap config, and therefore pass this config with the user_data argument. But this did not work, the config was not loaded during initial startup of the server. While troubleshooting, we noticed that there is the configDrive-Flag available in the API (API-DOCS), but not in the terraform provider. Leveraging this flag in an API-Call made the bootstrap config load during initial startup of the server
Proposed solution
We want to use the configDrive-Flag, which is available in the API, also in terraform, because we assume that this will resolve the bug with the bootstrap config not loading during initial startup, which was the case when we used the API directly.
Alternative solutions (optional)
A clear and concise description of any alternative solutions or features you've considered. (optional)
Additional information
Feel free to add any additional information here.