Skip to content

Commit

Permalink
Revert "use auto allocated network, bypass port creation."
Browse files Browse the repository at this point in the history
This reverts commit 16f011dec5a10b982c912447425f6e30c1f81be5.
  • Loading branch information
zonca committed Mar 2, 2023
1 parent 16767b6 commit 43ff268
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions contrib/terraform/openstack/modules/compute/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -336,7 +336,7 @@ resource "openstack_compute_instance_v2" "k8s_master" {
}

network {
name = "auto_allocated_network"
port = element(openstack_networking_port_v2.k8s_master_port.*.id, count.index)
}

dynamic "scheduler_hints" {
Expand Down Expand Up @@ -940,11 +940,10 @@ resource "openstack_networking_floatingip_associate_v2" "bastion" {
}


resource "openstack_compute_floatingip_associate_v2" "k8s_master" {
resource "openstack_networking_floatingip_associate_v2" "k8s_master" {
count = var.number_of_k8s_masters
floating_ip = var.k8s_master_fips[count.index]
instance_id = element(openstack_compute_instance_v2.k8s_master.*.id, count.index)
wait_until_associated = true
port_id = element(openstack_networking_port_v2.k8s_master_port.*.id, count.index)
}

resource "openstack_networking_floatingip_associate_v2" "k8s_masters" {
Expand Down

0 comments on commit 43ff268

Please sign in to comment.