Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Krish Moodbidri
Terraform Openstack
Commits
21071a8f
Commit
21071a8f
authored
Jul 29, 2019
by
Ishan Patel
Browse files
variable for compute nodes
parent
2a6d5306
Changes
2
Hide whitespace changes
Inline
Side-by-side
main.tf
View file @
21071a8f
...
...
@@ -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
{
...
...
vars.tf
View file @
21071a8f
...
...
@@ -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"
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment