diff --git a/aks/application/resources.tf b/aks/application/resources.tf index e852038..e05010f 100644 --- a/aks/application/resources.tf +++ b/aks/application/resources.tf @@ -9,7 +9,7 @@ locals { prometheus_scrape_annotations = var.enable_prometheus_monitoring ? { "prometheus.io/scrape" = "true" "prometheus.io/path" = "/metrics" - "prometheus.io/port" = var.web_port + "prometheus.io/port" = var.is_web ? var.web_port : var.worker_port } : {} logit_annotations = var.enable_logit ? { diff --git a/aks/application/tfdocs.md b/aks/application/tfdocs.md index 9a61311..7e7824a 100644 --- a/aks/application/tfdocs.md +++ b/aks/application/tfdocs.md @@ -56,6 +56,7 @@ No modules. | [service\_short](#input\_service\_short) | Short name of the service | `string` | `null` | no | | [web\_external\_hostnames](#input\_web\_external\_hostnames) | List of external hostnames for the web application | `list(string)` | `[]` | no | | [web\_port](#input\_web\_port) | Port of the web application | `number` | `3000` | no | +| [worker\_port](#input\_worker\_port) | Port of the worker application | `number` | `9394` | no | ## Outputs diff --git a/aks/application/variables.tf b/aks/application/variables.tf index 3ab7c11..2948743 100644 --- a/aks/application/variables.tf +++ b/aks/application/variables.tf @@ -98,6 +98,13 @@ variable "web_port" { description = "Port of the web application" } +variable "worker_port" { + type = number + nullable = false + default = 9394 + description = "Port of the worker application" +} + variable "probe_path" { type = string default = "/healthcheck"