Skip to content

Commit

Permalink
feat: whitelisting not available on private cluster
Browse files Browse the repository at this point in the history
Signed-off-by: Fredrik Klingenberg <[email protected]>
  • Loading branch information
fredrkl committed Nov 13, 2023
1 parent d04c4e0 commit 57d6cbc
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 11 deletions.
12 changes: 6 additions & 6 deletions terraform/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,12 @@ module "network" {
}

module "aks" {
source = "./modules/aks"
resource_group = azurerm_resource_group.aks
subnet_id = module.network.aks_dataplane_subnet_id
api_server_subnet_id = module.network.api_server_subnet_id
api_server_identity_id = module.identities.aks_identity_id
api_server_allowed_cidr_blocks = module.network.jumphost_subnet_cidr_blocks
source = "./modules/aks"
resource_group = azurerm_resource_group.aks
subnet_id = module.network.aks_dataplane_subnet_id
api_server_subnet_id = module.network.api_server_subnet_id
api_server_identity_id = module.identities.aks_identity_id
# api_server_allowed_cidr_blocks = module.network.jumphost_subnet_cidr_blocks

count = var.enable_aks ? 1 : 0
}
Expand Down
2 changes: 1 addition & 1 deletion terraform/modules/aks/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ resource "azurerm_kubernetes_cluster" "example" {
api_server_access_profile {
vnet_integration_enabled = true
subnet_id = var.api_server_subnet_id
authorized_ip_ranges = var.api_server_allowed_cidr_blocks
# authorized_ip_ranges = var.api_server_allowed_cidr_blocks
}

tags = {
Expand Down
8 changes: 4 additions & 4 deletions terraform/modules/aks/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ variable "api_server_identity_id" {
description = "The ID of the identity to assign to the AKS API server."
}

variable "api_server_allowed_cidr_blocks" {
type = list(string)
description = "The CIDR blocks allowed to access the AKS API server."
}
#variable "api_server_allowed_cidr_blocks" {
# type = list(string)
# description = "The CIDR blocks allowed to access the AKS API server."
#}

0 comments on commit 57d6cbc

Please sign in to comment.