commit 7923a39de3df9994312c2e2f0647735af71783e5 Author: pierre Date: Wed Jun 19 13:49:59 2024 +0100 :boom: add all the files diff --git a/allowlist.yaml b/allowlist.yaml new file mode 100644 index 0000000..7d4cb10 --- /dev/null +++ b/allowlist.yaml @@ -0,0 +1,7 @@ +kind: KubeletConfiguration +apiVersion: kubelet.config.k8s.io/v1beta1 +cgroupDriver: "systemd" +allowedUnsafeSysctls: +- "net.ipv4.conf.all.src_valid_mark" +- "net.ipv6.conf.all.disable_ipv6" +- "net.ipv4.ip_forward" diff --git a/gluetun-secret-japan.yaml b/gluetun-secret-japan.yaml new file mode 100644 index 0000000..aca81d6 --- /dev/null +++ b/gluetun-secret-japan.yaml @@ -0,0 +1,14 @@ +apiVersion: v1 +data: + VPN_ENDPOINT_IP: MTkzLjE0OC4xNi4y + VPN_ENDPOINT_PORT: NTE4MjA= + WIREGUARD_PRIVATE_KEY: S0xqMkprOEpzTklPSGlLck15QTZDcWNpTVlVR3JXS2U0WXplL21pT2RrRT0= + WIREGUARD_PUBLIC_KEY: NWZGaHV6SVFQdThDNHR5U0p1Q0pZZy8xM2c3NUFQRnRNbnFuM29lQ3B4az0= +kind: Secret +metadata: + creationTimestamp: "2024-04-24T08:54:01Z" + name: gluetun-secret-japan + namespace: servarr + resourceVersion: "10288795" + uid: 66128a5d-5f9b-4e33-a0ca-eadc214b2ae2 +type: Opaque diff --git a/gluetun-secret-netherland.yaml b/gluetun-secret-netherland.yaml new file mode 100644 index 0000000..7edb382 --- /dev/null +++ b/gluetun-secret-netherland.yaml @@ -0,0 +1,14 @@ +apiVersion: v1 +data: + VPN_ENDPOINT_IP: MjEyLjguMjUzLjEzNw== + VPN_ENDPOINT_PORT: NTE4MjA= + WIREGUARD_PRIVATE_KEY: Y0grY0hLd3FMeXV3UlVlZy8wRjFYWVlDQVM4bkQwWGsxNmVOQlVLc2tYbz0= + WIREGUARD_PUBLIC_KEY: VVJwZVp4dHlVWEFVVUEwTVdjRmRDU2E3RitNdmNoSjRlTlNKVWV0S0VHaz0= +kind: Secret +metadata: + creationTimestamp: "2024-04-24T08:56:38Z" + name: gluetun-secret-netherland + namespace: servarr + resourceVersion: "10289141" + uid: 89c92ca4-03e3-4f46-807f-94fd512c151a +type: Opaque diff --git a/qbittorrent.kube.yaml b/qbittorrent.kube.yaml new file mode 100644 index 0000000..f2c0e98 --- /dev/null +++ b/qbittorrent.kube.yaml @@ -0,0 +1,86 @@ +apiVersion: v1 +kind: Namespace +metadata: + name: servarr +--- +apiVersion: apps/v1 +kind: Deployment +metadata: + name: qbittorrent + namespace: servarr +spec: + replicas: 1 + selector: + matchLabels: + app: qbittorrent + template: + metadata: + labels: + app: qbittorrent + spec: + hostNetwork: false + nodeName: kube-master + containers: + - name: qbittorrent + image: lscr.io/linuxserver/qbittorrent:latest + imagePullPolicy: IfNotPresent + env: + - name: TZ + value: "Etc/UTC" + - name: PUID + value: "1000" + - name: PGID + value: "1000" + - name: WEBUI_PORT + value: "8080" + volumeMounts: + - name: qbittorrent-config + mountPath: /config + - name: servarr-data + mountPath: /disk + ports: + - containerPort: 8080 + protocol: TCP + - containerPort: 6881 + protocol: TCP + - containerPort: 6881 + protocol: UDP + +# securityContext: +# sysctls: +# - name: net.ipv4.conf.all.src_valid_mark +# value: "1" +# - name: net.ipv6.conf.all.disable_ipv6 +# value: "1" + + + volumes: + - name: servarr-data + hostPath: + path: /data + - name: qbittorrent-config + hostPath: + path: /opt/kubernetes/Servarr_kube/configs/qbittorrent/ +--- +apiVersion: v1 +kind: Service +metadata: + name: qbittorrent + namespace: servarr +spec: + ports: + - protocol: TCP + name: web-interface + port: 8080 +# nodePort: 30302 + - protocol: TCP + name: torrent-tcp + port: 6881 +# nodePort: 31609 + - protocol: UDP + name: torrents-udp + port: 6881 +# nodePort: 31609 +# type: NodePort + selector: + app: qbittorrent diff --git a/servarr.kube.yaml b/servarr.kube.yaml new file mode 100644 index 0000000..a58b4fd --- /dev/null +++ b/servarr.kube.yaml @@ -0,0 +1,296 @@ +apiVersion: v1 +kind: Namespace +metadata: + name: servarr +--- +apiVersion: apps/v1 +kind: Deployment +metadata: + name: servarr + namespace: servarr +spec: + replicas: 1 + selector: + matchLabels: + app: servarr + template: + metadata: + labels: + app: servarr + spec: + hostNetwork: false + nodeName: kube-master + containers: + - name: gluetun + image: qmcgaw/gluetun:v3 + imagePullPolicy: Always + securityContext: + # sysctls: + # - name: net.ipv4.conf.all.src_valid_mark + # value: "1" + # - name: net.ipv6.conf.all.disable_ipv6 + # value: "1" + privileged: true + capabilities: + add: ["NET_ADMIN", "NET_RAW"] + env: + - name: VPN_SERVICE_PROVIDER + value: "custom" + - name: VPN_TYPE + value: "wireguard" + + - name: VPN_ENDPOINT_IP + valueFrom: + secretKeyRef: + name: gluetun-secret-netherland + key: VPN_ENDPOINT_IP + - name: VPN_ENDPOINT_PORT + valueFrom: + secretKeyRef: + name: gluetun-secret-netherland + key: VPN_ENDPOINT_PORT + - name: WIREGUARD_PUBLIC_KEY + valueFrom: + secretKeyRef: + name: gluetun-secret-netherland + key: WIREGUARD_PUBLIC_KEY + - name: WIREGUARD_PRIVATE_KEY + valueFrom: + secretKeyRef: + name: gluetun-secret-netherland + key: WIREGUARD_PRIVATE_KEY + + - name: WIREGUARD_ADDRESSES + value: "10.2.0.2/32" + - name: FIREWALL_INPUT_PORTS + value: "8081,7878,9696,9091,51413,8080,6881,8989,8191" + + - name: sickchill + image: sickchill/sickchill:latest + imagePullPolicy: Always + volumeMounts: + - name: host-localtime + mountPath: /etc/localtime + - name: sickchill-cache + mountPath: /app/sickchill/sickchill/gui/slick/cache + - name: sickchill-data + mountPath: /data + - name: sickchill-downloads + mountPath: /downloads + - name: sickchill-tv + mountPath: /tv + - name: servarr-data + mountPath: /disk + ports: + - containerPort: 8081 + name: sickchill-port + securityContext: + privileged: true + capabilities: + add: ["NET_ADMIN", "NET_RAW"] + + + - name: radarr + image: lscr.io/linuxserver/radarr:latest + imagePullPolicy: Always + env: + - name: PUID + value: "1000" + - name: PGID + value: "1000" + - name: TZ + value: "Etc/UTC" + + volumeMounts: + - name: radarr-config + mountPath: /config + - name: servarr-data + mountPath: /mnt/media + - name: servarr-data + mountPath: /disk + - name: radarr-download + mountPath: /mnt/downloads + + ports: + - containerPort: 7878 + name: radarr-port + + - name: prowlarr +# image: linuxserver/prowlarr:latest + image: lscr.io/linuxserver/prowlarr:latest + imagePullPolicy: Always + env: + - name: PUID + value: "1000" + - name: PGID + value: "1000" + - name: TZ + value: "Etc/UTC" + volumeMounts: + - name: prowlarr-config + mountPath: /config + - name: servarr-data + mountPath: /disk + ports: + - containerPort: 9696 + name: prowlarr-port + + - name: sonarr + image: lscr.io/linuxserver/sonarr:latest + imagePullPolicy: Always + env: + - name: PUID + value: "1000" + - name: PGID + value: "1000" + - name: TZ + value: "Etc/UTC" + volumeMounts: + - name: sonarr-config + mountPath: /config + - name: servarr-data + mountPath: /disk + ports: + - containerPort: 8989 + name: sonarr-port + +# - name: flaresolverr +# image: ghcr.io/flaresolverr/flaresolverr:latest +# imagePullPolicy: Always +# env: +# - name: LOG_LEVEL +# value: "info" +# - name: LOG_HTML +# value: "false" +# - name: CAPTCHA_SOLVER +# value: "none" +# - name: TZ +# value: "Etc/UTC" +# ports: +# - containerPort: 8191 +# name: flare-port + + securityContext: + sysctls: + - name: net.ipv4.conf.all.src_valid_mark + value: "1" + - name: net.ipv6.conf.all.disable_ipv6 + value: "1" + + + volumes: + - name: servarr-data + hostPath: + path: /data + - name: host-localtime + hostPath: + path: /etc/localtime + - name: sickchill-cache + hostPath: + path: /opt/kubernetes/Servarr_kube/configs/sickchill/cache + - name: sickchill-data + hostPath: + path: /opt/kubernetes/Servarr_kube/configs/sickchill/data + - name: sickchill-downloads + hostPath: + path: /opt/kubernetes/Servarr_kube/configs/sickchill/downloads + - name: sickchill-tv + hostPath: + path: /opt/kubernetes/Servarr_kube/configs/sickchill/tv + - name: radarr-config + hostPath: + path: /opt/kubernetes/Servarr_kube/configs/radarr/ + - name: radarr-download + hostPath: + path: /data/download + - name: prowlarr-config + hostPath: + path: /opt/kubernetes/Servarr_kube/configs/prowlarr/ + - name: sonarr-config + hostPath: + path: /opt/kubernetes/Servarr_kube/configs/sonarr/ + +--- +apiVersion: v1 +kind: Service +metadata: + name: sickchill + namespace: servarr +spec: + ports: + - name: sickchill + port: 80 + targetPort: sickchill-port + protocol: TCP +# nodePort: 30865 +# type: NodePort + selector: + app: servarr + +--- +apiVersion: v1 +kind: Service +metadata: + name: radarr + namespace: servarr +spec: + ports: + - name: radarr + port: 80 + targetPort: radarr-port + protocol: TCP +# nodePort: 31084 +# type: NodePort + selector: + app: servarr +--- +apiVersion: v1 +kind: Service +metadata: + name: prowlarr + namespace: servarr +spec: + ports: + - name: prowlarr + port: 80 + targetPort: prowlarr-port + protocol: TCP +# nodePort: 31884 +# type: NodePort + selector: + app: servarr +--- +apiVersion: v1 +kind: Service +metadata: + name: sonarr + namespace: servarr +spec: + ports: + - name: sonarr + port: 80 + targetPort: sonarr-port + protocol: TCP +# nodePort: 32235 +# type: NodePort + selector: + app: servarr + + + +--- +apiVersion: v1 +kind: Service +metadata: + name: flaresolverr + namespace: servarr +spec: + ports: + - name: flaresolverr + port: 80 + targetPort: flare-port + protocol: TCP +# nodePort: 32235 +# type: NodePort + selector: + app: servarr