Commit 21071a8f authored by Ishan Patel's avatar Ishan Patel
Browse files

variable for compute nodes

parent 2a6d5306
......@@ -5,8 +5,8 @@ resource "openstack_compute_keypair_v2" "keypair" {
# creates dmznet
resource "openstack_networking_network_v2" "external_net" {
name = var.external-net
admin_state_up = var.admin-state-up
name = var.external-net
admin_state_up = var.admin-state-up
}
resource "openstack_networking_subnet_v2" "external_subnet" {
......@@ -137,7 +137,7 @@ resource "openstack_compute_instance_v2" "c0" {
flavor_name = var.flavor
key_pair = openstack_compute_keypair_v2.keypair.name
security_groups = ["default"]
count = 2
count = var.compute_node_count
# defines the networks of the instance
network {
......
......@@ -44,6 +44,9 @@ variable "image_ood" {
variable "image_compute" {
default = "CentOS-7-x86_64-GenericCloud-1905"
}
variable "compute_node_count" {
default = 2
}
variable "keypair-name" {
default = "os-gen-keypair"
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment