set techniitum to nodeport to get source ip clients and remove bind [ci skip]
This commit is contained in:
parent
63b0fbdcff
commit
28107b7328
4 changed files with 23 additions and 20 deletions
|
|
@ -52,7 +52,7 @@ variable "finance_app_gocardless_secret_key" {}
|
|||
|
||||
resource "null_resource" "core_services" {
|
||||
# List all the core modules that must be provisioned first
|
||||
depends_on = [module.metallb, module.bind]
|
||||
depends_on = [module.metallb]
|
||||
}
|
||||
|
||||
module "blog" {
|
||||
|
|
@ -63,12 +63,12 @@ module "blog" {
|
|||
depends_on = [null_resource.core_services]
|
||||
}
|
||||
|
||||
module "bind" {
|
||||
source = "./bind"
|
||||
db_viktorbarzin_me = var.bind_db_viktorbarzin_me
|
||||
db_viktorbarzin_lan = var.bind_db_viktorbarzin_lan
|
||||
named_conf_options = var.bind_named_conf_options
|
||||
}
|
||||
# module "bind" {
|
||||
# source = "./bind"
|
||||
# db_viktorbarzin_me = var.bind_db_viktorbarzin_me
|
||||
# db_viktorbarzin_lan = var.bind_db_viktorbarzin_lan
|
||||
# named_conf_options = var.bind_named_conf_options
|
||||
# }
|
||||
|
||||
module "dbaas" {
|
||||
source = "./dbaas"
|
||||
|
|
|
|||
|
|
@ -12,7 +12,8 @@ module "tls_secret" {
|
|||
tls_secret_name = var.tls_secret_name
|
||||
}
|
||||
|
||||
resource "kubernetes_deployment" "technitium" {
|
||||
# resource "kubernetes_deployment" "technitium" {
|
||||
resource "kubernetes_daemonset" "technitium" {
|
||||
metadata {
|
||||
name = "technitium"
|
||||
namespace = "technitium"
|
||||
|
|
@ -21,7 +22,7 @@ resource "kubernetes_deployment" "technitium" {
|
|||
}
|
||||
}
|
||||
spec {
|
||||
replicas = 1
|
||||
# replicas = 1
|
||||
selector {
|
||||
match_labels = {
|
||||
app = "technitium"
|
||||
|
|
@ -38,14 +39,14 @@ resource "kubernetes_deployment" "technitium" {
|
|||
image = "technitium/dns-server:latest"
|
||||
name = "technitium"
|
||||
resources {
|
||||
limits = {
|
||||
cpu = "1"
|
||||
memory = "1Gi"
|
||||
}
|
||||
requests = {
|
||||
cpu = "1"
|
||||
memory = "1Gi"
|
||||
}
|
||||
# limits = {
|
||||
# cpu = "1"
|
||||
# memory = "1Gi"
|
||||
# }
|
||||
# requests = {
|
||||
# cpu = "1"
|
||||
# memory = "1Gi"
|
||||
# }
|
||||
}
|
||||
port {
|
||||
container_port = 5380
|
||||
|
|
@ -110,8 +111,9 @@ resource "kubernetes_service" "technitium-dns" {
|
|||
}
|
||||
|
||||
spec {
|
||||
type = "LoadBalancer"
|
||||
external_traffic_policy = "Cluster"
|
||||
type = "LoadBalancer"
|
||||
# external_traffic_policy = "Cluster"
|
||||
external_traffic_policy = "Local"
|
||||
selector = {
|
||||
app = "technitium"
|
||||
|
||||
|
|
@ -129,7 +131,8 @@ resource "kubernetes_ingress_v1" "technitium" {
|
|||
name = "technitium-ingress"
|
||||
namespace = "technitium"
|
||||
annotations = {
|
||||
"kubernetes.io/ingress.class" = "nginx"
|
||||
"kubernetes.io/ingress.class" = "nginx"
|
||||
"nginx.ingress.kubernetes.io/affinity" = "cookie"
|
||||
"nginx.ingress.kubernetes.io/auth-tls-verify-client" = "on"
|
||||
"nginx.ingress.kubernetes.io/auth-tls-secret" = "default/ca-secret"
|
||||
}
|
||||
|
|
|
|||
Binary file not shown.
BIN
terraform.tfvars
BIN
terraform.tfvars
Binary file not shown.
Loading…
Add table
Add a link
Reference in a new issue