From 477582516f90708729b23b72e36cf4e4caaa0ea0 Mon Sep 17 00:00:00 2001 From: Lukas Steiner Date: Mon, 10 Jan 2022 01:36:08 +0100 Subject: [PATCH] add scsi bus support for openstack --- k3s-openstack/main.tf | 2 +- k3s-openstack/variables.tf | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/k3s-openstack/main.tf b/k3s-openstack/main.tf index 0dcf493..60352fb 100644 --- a/k3s-openstack/main.tf +++ b/k3s-openstack/main.tf @@ -34,7 +34,7 @@ module "k3s" { custom_cloud_config_runcmd = var.custom_cloud_config_runcmd bootstrap_token_id = var.bootstrap_token_id bootstrap_token_secret = var.bootstrap_token_secret - persistent_volume_dev = "/dev/vdb" + persistent_volume_dev = var.image_scsi_bus ? "/dev/sdb" : "/dev/vdb" } resource "openstack_compute_instance_v2" "node" { diff --git a/k3s-openstack/variables.tf b/k3s-openstack/variables.tf index 19b1794..1072ae8 100644 --- a/k3s-openstack/variables.tf +++ b/k3s-openstack/variables.tf @@ -8,6 +8,10 @@ variable "image_id" { description = "instead of a image name, the id can be given" } +variable "image_scsi_bus" { + default = false +} + variable "flavor_name" { default = "m1.small" }