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

Not able to disable the authorized Ip ranges in AKS API server using Terraform. #23317

Closed
1 task done
selvanayaki678 opened this issue Sep 19, 2023 · 4 comments
Closed
1 task done

Comments

@selvanayaki678
Copy link

Is there an existing issue for this?

  • I have searched the existing issues

Community Note

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
  • Please do not leave "+1" or "me too" comments, they generate extra noise for issue followers and do not help prioritize the request
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment and review the contribution guide to help.

Terraform Version

0.15.5

AzureRM Provider Version

3.59.0

Affected Resource(s)/Data Source(s)

azurerm_kubernetes_cluster

Terraform Configuration Files

resource "azurerm_kubernetes_cluster" "akstest"
		name = "test-aks"
		resource_group_name = "test-rg"
		location = "East US 2"		
		kubernetes_version = "1.25.11"
		api_server_access_profile {
			authorized_ip_ranges = [somepublicips]
		}

		network_profile {
			network_plugin = "azure"
			network_policy = "azure"
            load_balancer_sku = "standard"
			outbound_type ="userDefinedRouting" 
		}
		default_node_pool {
			name = "default"
			type = "VirtualMachineScaleSets"
			orchestrator_version = "1.25.11
			temporary_name_for_rotation = "systemtest"
			enable_host_encryption = true
			node_count = 2
			vm_size = "Standard_D8s_v5"
			os_disk_size_gb = 100
			max_pods = 30		
			vnet_subnet_id 	= "subnetid"
			enable_node_public_ip = false
			enable_auto_scaling = true
			min_count = 2
			max_count =3
		}		
	
		identity {
			type = "SystemAssigned"
		}

		azure_active_directory_role_based_access_control {
			managed  = true
		}
		tags = {
			environment = var.basic.envrnmt
		}
		
		lifecycle {
			ignore_changes = [tags ]
		}
    }

Debug Output/Panic Output

In the aks cluster, it enables the Authorized IP ranges with some IPs whatever specified in this block
	api_server_access_profile {
			authorized_ip_ranges = [somepublicips]
		}

After making the authorized_ip_ranges is empty. Its not disabling the authorized ip ranges in aks.

Expected Behaviour

Not able to disable the authorized_ip_ranges feature in AKS using terraform.

Actual Behaviour

Need a terraform configuration to disable to authorized_ip_ranges feature in AKS

Steps to Reproduce

No response

Important Factoids

No response

References

No response

@selvanayaki678 selvanayaki678 changed the title Not able disable the authorized Ip ranges in AKS API server using Terraform Not able to disable the authorized Ip ranges in AKS API server using Terraform. Sep 19, 2023
@github-actions github-actions bot added the v/3.x label Sep 19, 2023
@stephybun
Copy link
Member

Thanks for raising this issue @selvanayaki678.

Since this is duplicate of #20085 I'm going to close this issue to make sure discussions remain in a centralised place. Please subscribe to #20085 for updates. Thanks!

@selvanayaki678
Copy link
Author

@stephybun When we will get the resolution for the above issue. Please respond

@mloskot
Copy link
Contributor

mloskot commented Nov 23, 2023

This is quite an issue that Terraform has no way to achieve the officially supported az aks update --api-server-authorized-ip-ranges="", see my #20085 (comment)

Copy link

github-actions bot commented May 1, 2024

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.
If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators May 1, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants