2017-12-05 20:48:47 +08:00
|
|
|
resource "null_resource" "dummy_dependency" {
|
2019-08-18 16:30:05 +08:00
|
|
|
triggers = {
|
2017-12-05 20:48:47 +08:00
|
|
|
dependency_id = "${var.router_id}"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
resource "openstack_networking_floatingip_v2" "k8s_master" {
|
2018-01-05 19:09:04 +08:00
|
|
|
count = "${var.number_of_k8s_masters}"
|
|
|
|
pool = "${var.floatingip_pool}"
|
|
|
|
depends_on = ["null_resource.dummy_dependency"]
|
2017-12-05 20:48:47 +08:00
|
|
|
}
|
|
|
|
|
2019-04-29 13:58:20 +08:00
|
|
|
resource "openstack_networking_floatingip_v2" "k8s_master_no_etcd" {
|
|
|
|
count = "${var.number_of_k8s_masters_no_etcd}"
|
|
|
|
pool = "${var.floatingip_pool}"
|
|
|
|
depends_on = ["null_resource.dummy_dependency"]
|
|
|
|
}
|
|
|
|
|
2017-12-05 20:48:47 +08:00
|
|
|
resource "openstack_networking_floatingip_v2" "k8s_node" {
|
2018-01-05 19:09:04 +08:00
|
|
|
count = "${var.number_of_k8s_nodes}"
|
|
|
|
pool = "${var.floatingip_pool}"
|
|
|
|
depends_on = ["null_resource.dummy_dependency"]
|
2017-12-05 20:48:47 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
resource "openstack_networking_floatingip_v2" "bastion" {
|
2018-01-05 19:09:04 +08:00
|
|
|
count = "${var.number_of_bastions}"
|
|
|
|
pool = "${var.floatingip_pool}"
|
|
|
|
depends_on = ["null_resource.dummy_dependency"]
|
2017-12-05 20:48:47 +08:00
|
|
|
}
|