Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Default route table + CIDR in module outputs #8

Open
jbphilippe-orange opened this issue Jul 3, 2023 · 0 comments
Open

Default route table + CIDR in module outputs #8

jbphilippe-orange opened this issue Jul 3, 2023 · 0 comments

Comments

@jbphilippe-orange
Copy link

Hi,

I would like to add new outputs in this module, for default route table ID, Name, and CIDR of the VPC.
_ Not mandatory, but it could be useful , to use these outputs with another resources _

In main.tf , we could add this :

data "flexibleengine_vpc_route_table" "default" {
  vpc_id = flexibleengine_vpc_v1.vpc[0].id

  depends_on = [flexibleengine_vpc_v1.vpc, flexibleengine_vpc_subnet_v1.vpc_subnets]
}

Then in outputs.tf :

output "default_rtb_id" {
  description = "id of the VPC route table (default)"
  value          = data.flexibleengine_vpc_route_table.default.id
}

output "default_rtb_name" {
  description = "Name of the VPC route table (default)"
  value          = data.flexibleengine_vpc_route_table.default.name
}

output "vpc_cidr" {
  description = "CIDR of the created VPC"
  value          = var.vpc_cidr
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant