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

Amend new attributes in network_profile block #585

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

lonegunmanb
Copy link
Member

Describe your changes

This pr amended missing new attributes in network_profile nested block.

It doesn't support outbound_ip_prefix_ids and outbound_ip_address_ids since they're about to be deprecated in AzureRM provider v4.

Issue number

#518

Checklist before requesting a review

  • The pr title can be used to describe what this pr did in CHANGELOG.md file
  • I have executed pre-commit on my machine
  • I have passed pr-check on my machine

Thanks for your cooperation!

main.tf Outdated Show resolved Hide resolved
main.tf Outdated
service_cidr = var.net_profile_service_cidr
service_cidrs = var.network_service_cidrs
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same here, it would be either service_cidr or service_cidrs.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've verified that we could set both service_cidr and service_cidrs @zioproto , here's my tfstate snippet:

"pod_cidr": "10.244.0.0/16",
                "pod_cidrs": [
                  "10.244.0.0/16",
                  "fded:4c8d:9691:939b::/64"
                ],
                "service_cidr": "10.0.0.0/16",
                "service_cidrs": [
                  "10.0.0.0/16",
                  "fd01:db8:deca::/108"
                ]

description = "(Optional) Specifies the data plane used for building the Kubernetes network. Possible values are `azure` and `cilium`. Defaults to `azure`. Disabling this forces a new resource to be created."
}

variable "network_ip_versions" {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We need a precondition that network_plugin_mode is set to overlay

default = null
description = <<-EOT
`nat_gateway_profile` block supports the following:
- `idle_timeout_in_minutes` - (Optional) Desired outbound flow idle timeout in minutes for the cluster load balancer. Must be between `4` and `120` inclusive. Defaults to `4`.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Doing a review of this PR I found out that the upstream provider documentation was wrong. Also for the parameters.

I opened a PR here:
https://github.com/hashicorp/terraform-provider-azurerm/pull/27287/files

default = null
description = <<-EOT
`nat_gateway_profile` block supports the following:
- `idle_timeout_in_minutes` - (Optional) Desired outbound flow idle timeout in minutes for the cluster load balancer. Must be between `4` and `120` inclusive. Defaults to `4`.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- `idle_timeout_in_minutes` - (Optional) Desired outbound flow idle timeout in minutes for the cluster load balancer. Must be between `4` and `120` inclusive. Defaults to `4`.
- `idle_timeout_in_minutes` - (Optional) Desired outbound flow idle timeout in minutes for the managed nat gateway. Must be between `4` and `120` inclusive. Defaults to `4`.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@lonegunmanb please review suggestion

description = <<-EOT
`nat_gateway_profile` block supports the following:
- `idle_timeout_in_minutes` - (Optional) Desired outbound flow idle timeout in minutes for the cluster load balancer. Must be between `4` and `120` inclusive. Defaults to `4`.
- `managed_outbound_ip_count` - (Optional) Count of desired managed outbound IPs for the cluster load balancer. Must be between `1` and `100` inclusive.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- `managed_outbound_ip_count` - (Optional) Count of desired managed outbound IPs for the cluster load balancer. Must be between `1` and `100` inclusive.
- `managed_outbound_ip_count` - (Optional) Count of desired managed outbound IPs for the managed nat gateway. Must be between `1` and `16` inclusive.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Development

Successfully merging this pull request may close these issues.

2 participants