Browse Source

add master_volume_type variable (#6524)

pull/6550/head
rptaylor 4 years ago
committed by GitHub
parent
commit
f2d2d080f6
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 11 additions and 0 deletions
  1. 1
      contrib/terraform/openstack/kubespray.tf
  2. 4
      contrib/terraform/openstack/modules/compute/main.tf
  3. 2
      contrib/terraform/openstack/modules/compute/variables.tf
  4. 4
      contrib/terraform/openstack/variables.tf

1
contrib/terraform/openstack/kubespray.tf

@ -51,6 +51,7 @@ module "compute" {
node_root_volume_size_in_gb = var.node_root_volume_size_in_gb
gfs_root_volume_size_in_gb = var.gfs_root_volume_size_in_gb
gfs_volume_size_in_gb = var.gfs_volume_size_in_gb
master_volume_type = var.master_volume_type
public_key_path = var.public_key_path
image = var.image
image_gfs = var.image_gfs

4
contrib/terraform/openstack/modules/compute/main.tf

@ -167,6 +167,7 @@ resource "openstack_compute_instance_v2" "k8s_master" {
uuid = data.openstack_images_image_v2.vm_image.id
source_type = "image"
volume_size = var.master_root_volume_size_in_gb
volume_type = var.master_volume_type
boot_index = 0
destination_type = "volume"
delete_on_termination = true
@ -215,6 +216,7 @@ resource "openstack_compute_instance_v2" "k8s_master_no_etcd" {
uuid = data.openstack_images_image_v2.vm_image.id
source_type = "image"
volume_size = var.master_root_volume_size_in_gb
volume_type = var.master_volume_type
boot_index = 0
destination_type = "volume"
delete_on_termination = true
@ -303,6 +305,7 @@ resource "openstack_compute_instance_v2" "k8s_master_no_floating_ip" {
uuid = data.openstack_images_image_v2.vm_image.id
source_type = "image"
volume_size = var.master_root_volume_size_in_gb
volume_type = var.master_volume_type
boot_index = 0
destination_type = "volume"
delete_on_termination = true
@ -346,6 +349,7 @@ resource "openstack_compute_instance_v2" "k8s_master_no_floating_ip_no_etcd" {
uuid = data.openstack_images_image_v2.vm_image.id
source_type = "image"
volume_size = var.master_root_volume_size_in_gb
volume_type = var.master_volume_type
boot_index = 0
destination_type = "volume"
delete_on_termination = true

2
contrib/terraform/openstack/modules/compute/variables.tf

@ -38,6 +38,8 @@ variable "gfs_root_volume_size_in_gb" {}
variable "gfs_volume_size_in_gb" {}
variable "master_volume_type" {}
variable "public_key_path" {}
variable "image" {}

4
contrib/terraform/openstack/variables.tf

@ -74,6 +74,10 @@ variable "gfs_volume_size_in_gb" {
default = 75
}
variable "master_volume_type" {
default = "Default"
}
variable "public_key_path" {
description = "The path of the ssh pub key"
default = "~/.ssh/id_rsa.pub"

Loading…
Cancel
Save