Skip to content

Commit

Permalink
fix: remove legacy ingress annotations
Browse files Browse the repository at this point in the history
The SSL redirection is no longer defined by these annotations, I think this is a leftover from ancient code. The HTTP -> HTTPS redirection is handled natively by the Traefik module and is enabled by default (a variable is available to deactivate it if necessary).
  • Loading branch information
lentidas committed Mar 1, 2024
1 parent a45b0d5 commit f3eee6a
Showing 1 changed file with 14 additions and 21 deletions.
35 changes: 14 additions & 21 deletions locals.tf
Original file line number Diff line number Diff line change
@@ -1,6 +1,12 @@
locals {
oauth2_proxy_image = "quay.io/oauth2-proxy/oauth2-proxy:v7.5.0"

ingress_annotations = {
"cert-manager.io/cluster-issuer" = "${var.cluster_issuer}"
"traefik.ingress.kubernetes.io/router.entrypoints" = "websecure"
"traefik.ingress.kubernetes.io/router.tls" = "true"
}

# values.yaml translated into HCL structures.
# Possible values available here -> https://github.com/bitnami/charts/tree/master/bitnami/thanos/
helm_values = [{
Expand Down Expand Up @@ -114,16 +120,10 @@ locals {
}]
}
ingress = {
enabled = true
annotations = {
"cert-manager.io/cluster-issuer" = "${var.cluster_issuer}"
"traefik.ingress.kubernetes.io/router.entrypoints" = "websecure"
"traefik.ingress.kubernetes.io/router.tls" = "true"
"ingress.kubernetes.io/ssl-redirect" = "true"
"kubernetes.io/ingress.allow-http" = "false"
}
tls = false
hostname = ""
enabled = true
annotations = local.ingress_annotations
tls = false
hostname = ""
extraRules = [
{
host = "thanos-bucketweb.${trimprefix("${var.subdomain}.${var.base_domain}", ".")}"
Expand Down Expand Up @@ -247,17 +247,10 @@ locals {
}]
}
ingress = {
enabled = true
annotations = {
"cert-manager.io/cluster-issuer" = "${var.cluster_issuer}"
"traefik.ingress.kubernetes.io/router.entrypoints" = "websecure"
"traefik.ingress.kubernetes.io/router.middlewares" = "traefik-withclustername@kubernetescrd"
"traefik.ingress.kubernetes.io/router.tls" = "true"
"ingress.kubernetes.io/ssl-redirect" = "true"
"kubernetes.io/ingress.allow-http" = "false"
}
tls = false
hostname = ""
enabled = true
annotations = local.ingress_annotations
tls = false
hostname = ""
extraRules = [
{
host = "thanos-query.${trimprefix("${var.subdomain}.${var.base_domain}", ".")}"
Expand Down

0 comments on commit f3eee6a

Please sign in to comment.