CPU limits cause CFS throttling even when nodes have idle capacity. Move to a request-only CPU model: keep CPU requests for scheduling fairness but remove all CPU limits. Memory limits stay (incompressible). Changes across 108 files: - Kyverno LimitRange policy: remove cpu from default/max in all 6 tiers - Kyverno ResourceQuota policy: remove limits.cpu from all 5 tiers - Custom ResourceQuotas: remove limits.cpu from 8 namespace quotas - Custom LimitRanges: remove cpu from default/max (nextcloud, onlyoffice) - RBAC module: remove cpu_limits variable and quota reference - Freedify factory: remove cpu_limit variable and limits reference - 86 deployment files: remove cpu from all limits blocks - 6 Helm values files: remove cpu under limits sections
73 lines
1.8 KiB
HCL
73 lines
1.8 KiB
HCL
variable "nfs_server" { type = string }
|
|
|
|
resource "kubernetes_namespace" "isponsorblocktv" {
|
|
metadata {
|
|
name = "isponsorblocktv"
|
|
labels = {
|
|
"istio-injection" : "disabled"
|
|
tier = local.tiers.edge
|
|
}
|
|
}
|
|
}
|
|
# Before running, setup config using
|
|
# docker run --rm -it -v ./youtube:/app/data -e TERM=$TERM -e COLORTERM=$COLORTERM ghcr.io/dmunozv04/isponsorblocktv --setup
|
|
|
|
module "nfs_data" {
|
|
source = "../../modules/kubernetes/nfs_volume"
|
|
name = "isponsorblocktv-data"
|
|
namespace = kubernetes_namespace.isponsorblocktv.metadata[0].name
|
|
nfs_server = var.nfs_server
|
|
nfs_path = "/mnt/main/isponsorblocktv/vermont"
|
|
}
|
|
|
|
# Mute and skip ads for vermont smart tv
|
|
resource "kubernetes_deployment" "isponsorblocktv-vermont" {
|
|
metadata {
|
|
name = "isponsorblocktv-vermont"
|
|
namespace = kubernetes_namespace.isponsorblocktv.metadata[0].name
|
|
labels = {
|
|
app = "isponsorblocktv-vermont"
|
|
tier = local.tiers.edge
|
|
}
|
|
}
|
|
spec {
|
|
replicas = 1
|
|
selector {
|
|
match_labels = {
|
|
app = "isponsorblocktv-vermont"
|
|
}
|
|
}
|
|
template {
|
|
metadata {
|
|
labels = {
|
|
app = "isponsorblocktv-vermont"
|
|
}
|
|
}
|
|
spec {
|
|
container {
|
|
image = "ghcr.io/dmunozv04/isponsorblocktv"
|
|
name = "isponsorblocktv-vermont"
|
|
volume_mount {
|
|
name = "data"
|
|
mount_path = "/app/data"
|
|
}
|
|
resources {
|
|
requests = {
|
|
cpu = "10m"
|
|
memory = "32Mi"
|
|
}
|
|
limits = {
|
|
memory = "256Mi"
|
|
}
|
|
}
|
|
}
|
|
volume {
|
|
name = "data"
|
|
persistent_volume_claim {
|
|
claim_name = module.nfs_data.claim_name
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|