mirror of
https://codeberg.org/scottslowe/learning-tools.git
synced 2026-03-11 09:04:37 +00:00
Merge pull request #13 from mestery/neutron-floatingips
terraform: Use Neutron floating IPs
This commit is contained in:
commit
86a8d5e5df
3 changed files with 4 additions and 3 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
|
@ -7,3 +7,4 @@
|
|||
.vagrant
|
||||
real-adminrc
|
||||
*.taskpaper
|
||||
terraform/tf-example/terraform.tfstate*
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@ resource "openstack_networking_router_interface_v2" "tf-router-interface" {
|
|||
subnet_id = "${openstack_networking_subnet_v2.tf-subnet.id}"
|
||||
}
|
||||
|
||||
resource "openstack_compute_floatingip_v2" "tf-fip" {
|
||||
resource "openstack_networking_floatingip_v2" "tf-fip" {
|
||||
pool = "${var.pool}"
|
||||
depends_on = ["openstack_networking_router_interface_v2.tf-router-interface"]
|
||||
}
|
||||
|
|
@ -33,7 +33,7 @@ resource "openstack_compute_instance_v2" "tf-instance" {
|
|||
flavor_name = "${var.flavor}"
|
||||
key_pair = "${var.key_pair}"
|
||||
security_groups = ["default"]
|
||||
floating_ip = "${openstack_compute_floatingip_v2.tf-fip.address}"
|
||||
floating_ip = "${openstack_networking_floatingip_v2.tf-fip.address}"
|
||||
network {
|
||||
uuid = "${openstack_networking_network_v2.tf-net.id}"
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,3 +1,3 @@
|
|||
output "address" {
|
||||
value = "${openstack_compute_floatingip_v2.tf-fip.address}"
|
||||
value = "${openstack_networking_floatingip_v2.tf-fip.address}"
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue