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

Add HTTP Application Routing option #8

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 10 additions & 9 deletions r-aks.tf
Original file line number Diff line number Diff line change
@@ -1,14 +1,15 @@
#tfsec:ignore:azure-container-use-rbac-permissions
resource "azurerm_kubernetes_cluster" "aks" {
name = local.aks_name
location = var.location
resource_group_name = var.resource_group_name
dns_prefix = replace(local.aks_name, "/[\\W_]/", "-")
kubernetes_version = var.kubernetes_version
sku_tier = var.aks_sku_tier
api_server_authorized_ip_ranges = var.private_cluster_enabled ? null : var.api_server_authorized_ip_ranges
node_resource_group = var.node_resource_group
enable_pod_security_policy = var.enable_pod_security_policy
name = local.aks_name
location = var.location
resource_group_name = var.resource_group_name
dns_prefix = replace(local.aks_name, "/[\\W_]/", "-")
kubernetes_version = var.kubernetes_version
sku_tier = var.aks_sku_tier
api_server_authorized_ip_ranges = var.private_cluster_enabled ? null : var.api_server_authorized_ip_ranges
node_resource_group = var.node_resource_group
enable_pod_security_policy = var.enable_pod_security_policy
http_application_routing_enabled = var.http_application_routing_enabled

private_cluster_enabled = var.private_cluster_enabled
private_dns_zone_id = var.private_cluster_enabled ? local.private_dns_zone : null
Expand Down
6 changes: 6 additions & 0 deletions variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,12 @@ variable "enable_pod_security_policy" {
default = false
}

variable "http_application_routing_enabled" {
description = "Should HTTP Application Routing be enabled?"
type = bool
default = false
}

variable "private_cluster_enabled" {
description = "Configure AKS as a Private Cluster: https://registry.terraform.io/providers/hashicorp/azurerm/latest/docs/resources/kubernetes_cluster#private_cluster_enabled"
type = bool
Expand Down