Files
apps-in-apps/values.yaml
T

684 lines
28 KiB
YAML

## Default values for the apps-in-apps chart (App-of-Apps pattern).
argocd:
# Namespace where ArgoCD (and thus the Application CRs) live.
namespace: argocd
# AppProject the generated Applications belong to.
project: default
# List of child ArgoCD Applications this chart renders.
# Each entry maps 1:1 to an `argoproj.io/v1alpha1 Application`.
applications:
- name: valheim
enabled: true
source:
repoURL: https://git.smokyzone.de/SmokyZone/valheim-gitops.git
targetRevision: main
path: .
helm:
# Extra --set style values merged into the valheim-gitops chart.
# Keep secrets out of here - override via a sealed/external secret
# or ArgoCD parameter overrides instead.
parameters: []
# valueFiles:
# - values.yaml
destination:
# Empty server means "the cluster ArgoCD itself runs in".
server: https://kubernetes.default.svc
namespace: valheim
syncPolicy:
automated:
prune: true
selfHeal: true
syncOptions:
- CreateNamespace=true
# External Secrets Operator - installed straight from its official Helm
# repo (no git source needed). CRDs are installed by the chart itself.
- name: external-secrets
enabled: true
source:
repoURL: https://charts.external-secrets.io
chart: external-secrets
targetRevision: "2.14.0"
helm:
values: |
installCRDs: true
destination:
server: https://kubernetes.default.svc
namespace: external-secrets
syncPolicy:
automated:
prune: true
selfHeal: true
syncOptions:
- CreateNamespace=true
# The SecretStore/ClusterSecretStore CRDs embed a very large OpenAPI
# schema; a plain `kubectl apply` stores the full manifest in the
# `kubectl.kubernetes.io/last-applied-configuration` annotation,
# which exceeds Kubernetes' 262144 byte annotation limit and fails
# with "metadata.annotations: Too long". Server-side apply avoids
# writing that annotation entirely.
- ServerSideApply=true
# OpenBao secret management backend + its ClusterSecretStore binding for ESO.
- name: openbao
enabled: true
source:
repoURL: https://git.smokyzone.de/SmokyZone/openbao.git
targetRevision: main
path: .
destination:
server: https://kubernetes.default.svc
namespace: openbao
syncPolicy:
automated:
prune: true
selfHeal: true
syncOptions:
- CreateNamespace=true
# Stakater Reloader - watches Secrets/ConfigMaps and triggers a rolling restart
# of workloads that reference them (e.g. after ESO refreshes a secret from OpenBao).
# Opt-in per workload via annotation, e.g. on a Deployment/StatefulSet:
# secret.reloader.stakater.com/reload: "<secret-name>"
# or `reloader.stakater.com/auto: "true"` to react to every referenced Secret/ConfigMap.
- name: reloader
enabled: true
source:
repoURL: https://stakater.github.io/stakater-charts
chart: reloader
targetRevision: "2.2.19"
helm:
values: |
reloader:
# The default strategy injects an env var into the pod template, which
# ArgoCD (selfHeal) would revert as drift. Annotations on the pod template
# are extra map keys and are ignored by ArgoCD's diff.
reloadStrategy: annotations
destination:
server: https://kubernetes.default.svc
namespace: reloader
syncPolicy:
automated:
prune: true
selfHeal: true
syncOptions:
- CreateNamespace=true
# Media stack: Jellyfin, Sonarr, Radarr, Prowlarr, SABnzbd, Bazarr, Seerr,
# FlareSolverr. LAN/VPN-only; see the media-gitops README for first-time setup.
- name: media
enabled: true
source:
repoURL: https://git.smokyzone.de/SmokyZone/media-gitops.git
targetRevision: main
path: .
destination:
server: https://kubernetes.default.svc
namespace: media
syncPolicy:
automated:
prune: true
selfHeal: true
syncOptions:
- CreateNamespace=true
# Tailscale subnet router: makes the node (and all *.smokyzone.de ingress
# hosts) reachable from the tailnet. Needs secret/tailscale (authkey) in OpenBao.
- name: tailscale
enabled: true
source:
repoURL: https://git.smokyzone.de/SmokyZone/tailscale-gitops.git
targetRevision: main
path: .
destination:
server: https://kubernetes.default.svc
namespace: tailscale
syncPolicy:
automated:
prune: true
selfHeal: true
syncOptions:
- CreateNamespace=true
# ingress-nginx - the only ingress controller. Was created by hand with kubectl; now
# managed here. NOTE: upstream ingress-nginx is retired (no releases since 03/2026) -
# plan a migration (Gateway API / Traefik) eventually.
#
# GeoIP: country database from DB-IP Lite (https://db-ip.com, CC BY 4.0), MaxMind-compatible,
# stored on the node in /var/lib/ingress-geoip so the controller always has a DB even if
# the internet is down at boot (without the file nginx would reject the config that uses
# $geoip2_country_code -> ALL ingresses down). The init container refreshes it when
# possible, the sidecar weekly; nginx reloads it daily (geoip2-autoreload-in-minutes).
# Hosts listed in the $geo_restricted_host map only answer to clients from Germany.
- name: ingress-nginx
enabled: true
source:
repoURL: https://kubernetes.github.io/ingress-nginx
chart: ingress-nginx
targetRevision: "4.15.1"
helm:
values: |
controller:
service:
type: NodePort
nodePorts:
http: 30081
https: 30444
# Also listen on the node's ports 80/443 directly, so LAN/Tailscale URLs need no port.
hostPort:
enabled: true
ports:
http: 80
https: 443
# A hostPort can't be held by two pods: replace the pod instead of surging.
updateStrategy:
type: RollingUpdate
rollingUpdate:
maxSurge: 0
maxUnavailable: 1
extraArgs:
maxmind-edition-ids: GeoLite2-Country
config:
# Real client IP for requests that come through Cloudflare (git, Home Assistant).
# The header is only trusted when the connection itself comes from a Cloudflare
# range, so nobody can spoof it by hitting the public IP directly.
enable-real-ip: "true"
forwarded-for-header: CF-Connecting-IP
proxy-real-ip-cidr: "173.245.48.0/20,103.21.244.0/22,103.22.200.0/22,103.31.4.0/22,141.101.64.0/18,108.162.192.0/18,190.93.240.0/20,188.114.96.0/20,197.234.240.0/22,198.41.128.0/17,162.158.0.0/15,104.16.0.0/13,104.24.0.0/14,172.64.0.0/13,131.0.72.0/22,2400:cb00::/32,2606:4700::/32,2803:f800::/32,2405:b500::/32,2405:8100::/32,2a06:98c0::/29,2c0f:f248::/32"
use-geoip2: "true"
geoip2-autoreload-in-minutes: "1440"
# Default upstreaminfo format + host and GeoIP country, for scripts/tv-access-report.sh.
log-format-upstream: '$remote_addr - $remote_user [$time_local] "$request" $status $body_bytes_sent "$http_referer" "$http_user_agent" $request_length $request_time [$proxy_upstream_name] [$proxy_alternative_upstream_name] $upstream_addr $upstream_response_length $upstream_response_time $upstream_status $req_id host=$host cc=$geoip2_country_code'
# Rate-limit hits as 429 (default 503 is indistinguishable from real outages).
limit-req-status-code: "429"
limit-conn-status-code: "429"
# Geo restriction for publicly exposed hosts: everything not from DE gets 403
# (also unknown/private IPs - LAN/Tailscale use the internal hostnames instead).
# Cloudflare-only hosts: since tv.smokyzone.de (DNS-only) reveals the home IP, the
# proxied hosts could be reached directly, bypassing Cloudflare. They only accept
# connections whose TCP peer ($realip_remote_addr, i.e. before real-ip rewriting)
# is a Cloudflare range - same ranges as proxy-real-ip-cidr above.
# ArgoCD/Mac reach git.smokyzone.de via public DNS = via Cloudflare, so they are fine.
http-snippet: |
map $host $geo_restricted_host {
default 0;
tv.smokyzone.de 1;
}
map "$geo_restricted_host:$geoip2_country_code" $geo_block {
default 0;
"~^1:(?!DE$)" 1;
}
map $host $cf_only_host {
default 0;
git.smokyzone.de 1;
homeassistant.smokyzone.de 1;
}
geo $realip_remote_addr $from_cloudflare {
default 0;
173.245.48.0/20 1; 103.21.244.0/22 1; 103.22.200.0/22 1; 103.31.4.0/22 1;
141.101.64.0/18 1; 108.162.192.0/18 1; 190.93.240.0/20 1; 188.114.96.0/20 1;
197.234.240.0/22 1; 198.41.128.0/17 1; 162.158.0.0/15 1; 104.16.0.0/13 1;
104.24.0.0/14 1; 172.64.0.0/13 1; 131.0.72.0/22 1;
2400:cb00::/32 1; 2606:4700::/32 1; 2803:f800::/32 1; 2405:b500::/32 1;
2405:8100::/32 1; 2a06:98c0::/29 1; 2c0f:f248::/32 1;
}
map "$cf_only_host:$from_cloudflare" $cf_block {
default 0;
"1:0" 1;
}
server-snippet: |
if ($geo_block) {
return 403;
}
if ($cf_block) {
return 403;
}
extraVolumes:
- name: geoip
hostPath:
path: /var/lib/ingress-geoip
type: DirectoryOrCreate
extraVolumeMounts:
- name: geoip
mountPath: /etc/ingress-controller/geoip
readOnly: true
extraInitContainers:
- name: geoip-init
image: curlimages/curl:8.23.0
securityContext:
runAsUser: 0
command: ["sh", "-c"]
args:
- |
D=/geoip
fetch() {
for m in $(date -u +%Y-%m) $(date -u -d "@$(( $(date +%s) - 2592000 ))" +%Y-%m); do
if curl -fsSL --retry 3 --max-time 120 -o $D/.dl.gz "https://download.db-ip.com/free/dbip-country-lite-$m.mmdb.gz" \
&& gunzip -c $D/.dl.gz > $D/.dl.mmdb && [ -s $D/.dl.mmdb ]; then
chmod 644 $D/.dl.mmdb && mv $D/.dl.mmdb $D/GeoLite2-Country.mmdb
rm -f $D/.dl.gz; echo "GeoIP: dbip-country-lite-$m"; return 0
fi
done
rm -f $D/.dl.gz $D/.dl.mmdb; return 1
}
fetch && exit 0
if [ -s $D/GeoLite2-Country.mmdb ]; then echo "GeoIP: download failed, keeping existing DB"; exit 0; fi
echo "GeoIP: no database available"; exit 1
volumeMounts:
- name: geoip
mountPath: /geoip
extraContainers:
- name: geoip-update
image: curlimages/curl:8.23.0
securityContext:
runAsUser: 0
command: ["sh", "-c"]
args:
- |
D=/geoip
while true; do
sleep 604800
for m in $(date -u +%Y-%m) $(date -u -d "@$(( $(date +%s) - 2592000 ))" +%Y-%m); do
if curl -fsSL --retry 3 --max-time 120 -o $D/.dl.gz "https://download.db-ip.com/free/dbip-country-lite-$m.mmdb.gz" \
&& gunzip -c $D/.dl.gz > $D/.dl.mmdb && [ -s $D/.dl.mmdb ]; then
chmod 644 $D/.dl.mmdb && mv $D/.dl.mmdb $D/GeoLite2-Country.mmdb; echo "GeoIP updated: $m"; break
fi
done
rm -f $D/.dl.gz $D/.dl.mmdb
done
resources:
requests:
cpu: 1m
memory: 8Mi
limits:
memory: 64Mi
volumeMounts:
- name: geoip
mountPath: /geoip
admissionWebhooks:
enabled: false
destination:
server: https://kubernetes.default.svc
namespace: ingress-nginx
syncPolicy:
automated:
prune: true
selfHeal: true
syncOptions:
- CreateNamespace=true
# Traefik - successor of ingress-nginx (IngressClass "traefik").
# Replacements for the nginx snippets, all as Middlewares in this namespace (extraObjects),
# referenced from Ingresses via traefik.ingress.kubernetes.io/router.middlewares:
# traefik-lan-only LAN + pod network only (the internal *.smokyzone.de UIs)
# traefik-cf-only TCP peer must be a Cloudflare range (git., homeassistant.)
# traefik-geoblock-de DE only (tv.smokyzone.de), plugin traefik-geoblock reading the
# DB-IP Lite country DB from /var/lib/ingress-geoip on the node
# traefik-gitea-* rate limit + HSTS for Gitea
# Real client IP: Cloudflare ranges are trusted for X-Forwarded-For on the entrypoints;
# everyone else's X-Forwarded-* headers are discarded. Allow lists without ipStrategy check
# the TCP peer (RemoteAddr), so they can't be fooled by headers.
# The geoblock plugin is downloaded from plugins.traefik.io at start. If that fails the
# middleware is missing and only routers using it (tv) fail - closed, the rest keeps working.
- name: traefik
enabled: true
source:
repoURL: https://traefik.github.io/charts
chart: traefik
targetRevision: "42.2.0"
helm:
values: |
ingressClass:
enabled: true
isDefaultClass: false
name: traefik
providers:
kubernetesIngress:
# Ingresses in these namespaces may reference the Middlewares above.
crossProviderNamespaces: [media, gitea, homeassistant]
service:
spec:
type: NodePort
ports:
web:
nodePort: 30082
http:
redirections:
entryPoint:
to: websecure
scheme: https
permanent: true
forwardedHeaders:
trustedIPs: &cloudflare ["173.245.48.0/20","103.21.244.0/22","103.22.200.0/22","103.31.4.0/22","141.101.64.0/18","108.162.192.0/18","190.93.240.0/20","188.114.96.0/20","197.234.240.0/22","198.41.128.0/17","162.158.0.0/15","104.16.0.0/13","104.24.0.0/14","172.64.0.0/13","131.0.72.0/22","2400:cb00::/32","2606:4700::/32","2803:f800::/32","2405:b500::/32","2405:8100::/32","2a06:98c0::/29","2c0f:f248::/32"]
websecure:
nodePort: 30445
forwardedHeaders:
trustedIPs: *cloudflare
transport:
respondingTimeouts:
# Default 60s would cut long uploads (git push, HA backups); websockets
# (HA, Jellyfin) and streams are not limited by it anyway.
readTimeout: 0
# hostPorts can't be held by two pods: replace the pod instead of surging.
updateStrategy:
type: RollingUpdate
rollingUpdate:
maxSurge: 0
maxUnavailable: 1
accessLog:
enabled: true
format: json
fields:
headers:
defaultMode: drop
names:
User-Agent: keep
X-IPCountry: keep
# Jellyfin clients send api_key in the query string - keep it out of the log.
queryParameters:
defaultMode: drop
experimental:
plugins:
geoblock:
moduleName: github.com/david-garcia-garcia/traefik-geoblock
version: v1.2.1
settings:
useUnsafe: true
deployment:
additionalVolumes:
- name: geoip
hostPath:
path: /var/lib/ingress-geoip
type: DirectoryOrCreate
# DB-IP Lite country DB (CC BY 4.0), MaxMind-compatible. Kept on the node so a DB
# exists even if the internet is down at boot; refreshed at start and weekly.
initContainers:
- name: geoip-init
image: curlimages/curl:8.23.0
securityContext:
runAsUser: 0
runAsNonRoot: false
command: ["sh", "-c"]
args:
- |
D=/geoip
fetch() {
for m in $(date -u +%Y-%m) $(date -u -d "@$(( $(date +%s) - 2592000 ))" +%Y-%m); do
if curl -fsSL --retry 3 --max-time 120 -o $D/.dl.gz "https://download.db-ip.com/free/dbip-country-lite-$m.mmdb.gz" \
&& gunzip -c $D/.dl.gz > $D/.dl.mmdb && [ -s $D/.dl.mmdb ]; then
chmod 644 $D/.dl.mmdb && mv $D/.dl.mmdb $D/GeoLite2-Country.mmdb
rm -f $D/.dl.gz; echo "GeoIP: dbip-country-lite-$m"; return 0
fi
done
rm -f $D/.dl.gz $D/.dl.mmdb; return 1
}
fetch && exit 0
if [ -s $D/GeoLite2-Country.mmdb ]; then echo "GeoIP: download failed, keeping existing DB"; exit 0; fi
echo "GeoIP: no database available"; exit 1
volumeMounts:
- name: geoip
mountPath: /geoip
additionalContainers:
- name: geoip-update
image: curlimages/curl:8.23.0
securityContext:
runAsUser: 0
runAsNonRoot: false
command: ["sh", "-c"]
args:
- |
D=/geoip
while true; do
sleep 604800
for m in $(date -u +%Y-%m) $(date -u -d "@$(( $(date +%s) - 2592000 ))" +%Y-%m); do
if curl -fsSL --retry 3 --max-time 120 -o $D/.dl.gz "https://download.db-ip.com/free/dbip-country-lite-$m.mmdb.gz" \
&& gunzip -c $D/.dl.gz > $D/.dl.mmdb && [ -s $D/.dl.mmdb ]; then
chmod 644 $D/.dl.mmdb && mv $D/.dl.mmdb $D/GeoLite2-Country.mmdb; echo "GeoIP updated: $m"; break
fi
done
rm -f $D/.dl.gz $D/.dl.mmdb
done
resources:
requests: {cpu: 1m, memory: 8Mi}
limits: {memory: 64Mi}
volumeMounts:
- name: geoip
mountPath: /geoip
additionalVolumeMounts:
- name: geoip
mountPath: /geoip
readOnly: true
resources:
requests: {cpu: 50m, memory: 96Mi}
limits: {memory: 512Mi}
extraObjects:
- apiVersion: traefik.io/v1alpha1
kind: Middleware
metadata:
name: lan-only
namespace: traefik
spec:
ipAllowList:
# Home network + pods (incl. Tailscale subnet router, 10.1.0.0/16), but NOT
# 192.168.2.218: the router's internet forward to the NodePort arrives SNATed
# as the node's own IP. LAN clients use hostPort 443 with their real IP.
sourceRange: ["192.168.2.0/25","192.168.2.128/26","192.168.2.192/28","192.168.2.208/29","192.168.2.216/31","192.168.2.219/32","192.168.2.220/30","192.168.2.224/27","10.1.0.0/16"]
- apiVersion: traefik.io/v1alpha1
kind: Middleware
metadata:
name: cf-only
namespace: traefik
spec:
ipAllowList:
# tv.smokyzone.de (DNS-only) reveals the home IP; the proxied hosts must not be
# reachable directly, bypassing Cloudflare.
sourceRange: ["173.245.48.0/20","103.21.244.0/22","103.22.200.0/22","103.31.4.0/22","141.101.64.0/18","108.162.192.0/18","190.93.240.0/20","188.114.96.0/20","197.234.240.0/22","198.41.128.0/17","162.158.0.0/15","104.16.0.0/13","104.24.0.0/14","172.64.0.0/13","131.0.72.0/22","2400:cb00::/32","2606:4700::/32","2803:f800::/32","2405:b500::/32","2405:8100::/32","2a06:98c0::/29","2c0f:f248::/32"]
- apiVersion: traefik.io/v1alpha1
kind: Middleware
metadata:
name: geoblock-de
namespace: traefik
spec:
plugin:
geoblock:
mode: enrichandblock
# TCP peer only: tv is not behind a proxy, headers would be spoofable.
ipHeaders: [remoteAddress]
countryHeader: X-IPCountry
allowedCountries: [DE]
defaultAllow: false
# Also private/unknown IPs get 403 - LAN/Tailscale use jellyfin.smokyzone.de.
allowPrivate: false
banIfError: true
disallowedStatusCode: 403
databaseSources:
default_ip2location:
enabled: false
dbip:
enabled: true
databaseType: mmdb
fieldsPreconfigured: maxmind_country
path: /geoip/GeoLite2-Country.mmdb
logLevel: warn
- apiVersion: traefik.io/v1alpha1
kind: Middleware
metadata:
name: gitea-ratelimit
namespace: traefik
spec:
rateLimit:
average: 10
burst: 50
# Behind Cloudflare: rightmost X-Forwarded-For entry = client as seen by CF.
sourceCriterion:
ipStrategy:
depth: 1
- apiVersion: traefik.io/v1alpha1
kind: Middleware
metadata:
name: gitea-hsts
namespace: traefik
spec:
headers:
stsSeconds: 31536000
stsIncludeSubdomains: false
destination:
server: https://kubernetes.default.svc
namespace: traefik
syncPolicy:
automated:
prune: true
selfHeal: true
# During the switch from ingress-nginx the NodePorts/hostPorts only become free once
# the old controller is gone.
retry:
limit: 10
backoff:
duration: 20s
factor: 2
maxDuration: 5m
syncOptions:
- CreateNamespace=true
- ServerSideApply=true
# Middlewares (extraObjects) are applied in the same sync as the Traefik CRDs.
- SkipDryRunOnMissingResource=true
# Gitea - Git server for all *-gitops repos (and thus ArgoCD's own source).
# Was created by hand with kubectl; now managed here.
# No chart-managed admin: the bootstrap user gitea_admin was deleted, the user's
# own account is admin. Empty username+password makes the chart skip
# configure_admin_user entirely - otherwise it would recreate gitea_admin with
# the chart's PUBLIC default password on every pod start.
# Careful: if Gitea does not come up, ArgoCD cannot fetch fixes from git either.
- name: gitea
enabled: true
source:
repoURL: https://dl.gitea.com/charts/
chart: gitea
targetRevision: "12.7.0"
helm:
values: |
image:
# Chart 12.7.0 ships 1.27.0; 1.27.1-1.27.3 contain security fixes.
tag: "1.27.3"
valkey-cluster:
enabled: false
postgresql:
enabled: false
postgresql-ha:
enabled: false
persistence:
enabled: true
strategy:
type: Recreate
rollingUpdate: null
gitea:
admin:
username: ""
password: ""
config:
database:
DB_TYPE: sqlite3
session:
PROVIDER: memory
cache:
ADAPTER: memory
queue:
TYPE: level
server:
PROTOCOL: http
DOMAIN: git.smokyzone.de
ROOT_URL: https://git.smokyzone.de/
HTTP_PORT: 3000
START_SSH_SERVER: false
SSH_DOMAIN: git-ssh.smokyzone.de
SSH_PORT: 2222
SSH_LISTEN_PORT: 2222
service:
DISABLE_REGISTRATION: true
security:
MIN_PASSWORD_LENGTH: 12
service:
http:
type: NodePort
port: 3000
nodePort: 30300
clusterIP:
ssh:
type: ClusterIP
port: 22
ingress:
enabled: true
className: nginx
annotations:
cert-manager.io/cluster-issuer: letsencrypt-dns-cloudflare
nginx.ingress.kubernetes.io/limit-rps: "10"
nginx.ingress.kubernetes.io/limit-burst-multiplier: "5"
nginx.ingress.kubernetes.io/proxy-body-size: "50m"
nginx.ingress.kubernetes.io/hsts: "true"
nginx.ingress.kubernetes.io/hsts-max-age: "31536000"
nginx.ingress.kubernetes.io/hsts-include-subdomains: "false"
hosts:
- host: git.smokyzone.de
paths:
- path: /
pathType: Prefix
tls:
- secretName: gitea-tls-letsencrypt
hosts:
- git.smokyzone.de
destination:
server: https://kubernetes.default.svc
namespace: gitea
syncPolicy:
automated:
prune: true
selfHeal: true
syncOptions:
- CreateNamespace=true
# Intel GPU device plugin: advertises the iGPU (UHD 630, /dev/dri) as the resource
# gpu.intel.com/i915, so Jellyfin can use QuickSync without running privileged.
# Manifest vendored in addons/intel-gpu-plugin (upstream v0.37.1; the upstream repo
# is too big for ArgoCD's git fetch timeout). MicroK8s runs the kubelet with
# --root-dir=$SNAP_COMMON/var/lib/kubelet, so the device-plugin socket path is patched.
- name: intel-gpu-plugin
enabled: true
source:
repoURL: https://git.smokyzone.de/SmokyZone/apps-in-apps.git
targetRevision: main
path: addons/intel-gpu-plugin
destination:
server: https://kubernetes.default.svc
namespace: intel-gpu-plugin
syncPolicy:
automated:
prune: true
selfHeal: true
syncOptions:
- CreateNamespace=true
# Home Assistant (container install, hostNetwork for LAN discovery).
# https://homeassistant.smokyzone.de - LAN/VPN only; see homeassistant-gitops README.
- name: homeassistant
enabled: true
source:
repoURL: https://git.smokyzone.de/SmokyZone/homeassistant-gitops.git
targetRevision: main
path: .
destination:
server: https://kubernetes.default.svc
namespace: homeassistant
syncPolicy:
automated:
prune: true
selfHeal: true
syncOptions:
- CreateNamespace=true