mirror of
https://github.com/michaelthomson0797/fleet-infra.git
synced 2026-02-04 13:09:53 +00:00
temp remove media namespace, make qbittorrent namespace
This commit is contained in:
@@ -1,34 +0,0 @@
|
|||||||
apiVersion: kustomize.toolkit.fluxcd.io/v1
|
|
||||||
kind: Kustomization
|
|
||||||
metadata:
|
|
||||||
name: media
|
|
||||||
namespace: flux-system
|
|
||||||
spec:
|
|
||||||
interval: 15m
|
|
||||||
path: ./media
|
|
||||||
prune: true # remove any elements later removed from the above path
|
|
||||||
timeout: 2m # if not set, this defaults to interval duration, which is 1h
|
|
||||||
sourceRef:
|
|
||||||
kind: GitRepository
|
|
||||||
name: flux-system
|
|
||||||
healthChecks:
|
|
||||||
- apiVersion: apps/v1
|
|
||||||
kind: Deployment
|
|
||||||
name: prowlarr
|
|
||||||
namespace: media
|
|
||||||
- apiVersion: apps/v1
|
|
||||||
kind: Deployment
|
|
||||||
name: qbittorrent
|
|
||||||
namespace: media
|
|
||||||
- apiVersion: apps/v1
|
|
||||||
kind: Deployment
|
|
||||||
name: radarr
|
|
||||||
namespace: media
|
|
||||||
- apiVersion: apps/v1
|
|
||||||
kind: Deployment
|
|
||||||
name: readarr
|
|
||||||
namespace: media
|
|
||||||
- apiVersion: apps/v1
|
|
||||||
kind: Deployment
|
|
||||||
name: sonarr
|
|
||||||
namespace: media
|
|
||||||
18
bootstrap/kustomizations/kustomization-qbittorrent.yaml
Normal file
18
bootstrap/kustomizations/kustomization-qbittorrent.yaml
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
apiVersion: kustomize.toolkit.fluxcd.io/v1
|
||||||
|
kind: Kustomization
|
||||||
|
metadata:
|
||||||
|
name: qbittorrent
|
||||||
|
namespace: flux-system
|
||||||
|
spec:
|
||||||
|
interval: 15m
|
||||||
|
path: ./qbittorrent
|
||||||
|
prune: true # remove any elements later removed from the above path
|
||||||
|
timeout: 2m # if not set, this defaults to interval duration, which is 1h
|
||||||
|
sourceRef:
|
||||||
|
kind: GitRepository
|
||||||
|
name: flux-system
|
||||||
|
healthChecks:
|
||||||
|
- apiVersion: apps/v1
|
||||||
|
kind: Deployment
|
||||||
|
name: qbittorrent
|
||||||
|
namespace: qbittorrent
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
apiVersion: v1
|
apiVersion: v1
|
||||||
kind: Namespace
|
kind: Namespace
|
||||||
metadata:
|
metadata:
|
||||||
name: media
|
name: qbittorrent
|
||||||
66
qbittorrent/deployment.yaml
Normal file
66
qbittorrent/deployment.yaml
Normal file
@@ -0,0 +1,66 @@
|
|||||||
|
apiVersion: apps/v1
|
||||||
|
kind: Deployment
|
||||||
|
metadata:
|
||||||
|
name: qbittorrent
|
||||||
|
namespace: qbittorrent
|
||||||
|
spec:
|
||||||
|
selector:
|
||||||
|
matchLabels:
|
||||||
|
app: qbittorrent
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
labels:
|
||||||
|
app: qbittorrent
|
||||||
|
spec:
|
||||||
|
containers:
|
||||||
|
- name: qbittorrent
|
||||||
|
image: lscr.io/linuxserver/qbittorrent:latest
|
||||||
|
envFrom:
|
||||||
|
- configMapRef:
|
||||||
|
name: qbittorrent-config
|
||||||
|
optional: false
|
||||||
|
ports:
|
||||||
|
- containerPort: 8080
|
||||||
|
name: http
|
||||||
|
protocol: TCP
|
||||||
|
volumeMounts:
|
||||||
|
- name: qbittorrent-config
|
||||||
|
mountPath: /config
|
||||||
|
- name: data
|
||||||
|
mountPath: /data/downloads
|
||||||
|
subPath: downloads
|
||||||
|
- name: gluetun
|
||||||
|
image: qmcgaw/gluetun
|
||||||
|
envFrom:
|
||||||
|
- configMapRef:
|
||||||
|
name: gluetun-config
|
||||||
|
securityContext:
|
||||||
|
capabilities:
|
||||||
|
add:
|
||||||
|
- NET_ADMIN
|
||||||
|
volumeMounts:
|
||||||
|
- name: wireguard-config-secret
|
||||||
|
mountPath: /gluetun/wireguard
|
||||||
|
initContainers:
|
||||||
|
- name: init-media-filesystem
|
||||||
|
image: busybox
|
||||||
|
command:
|
||||||
|
- /bin/sh
|
||||||
|
- -c
|
||||||
|
- |
|
||||||
|
mkdir -p -v /data/downloads/movies /data/downloads/tv /data/downloads/books /data/downloads/audiobooks /data/media/movies /data/media/tv /data/media/books /data/media/audiobooks
|
||||||
|
chown -R 1000:1000 /data
|
||||||
|
chmod -R a=,a+rX,u+w,g+w /data
|
||||||
|
volumeMounts:
|
||||||
|
- mountPath: /data
|
||||||
|
name: data
|
||||||
|
volumes:
|
||||||
|
- name: qbittorrent-config
|
||||||
|
persistentVolumeClaim:
|
||||||
|
claimName: qbittorrent-config
|
||||||
|
- name: data
|
||||||
|
persistentVolumeClaim:
|
||||||
|
claimName: data
|
||||||
|
- name: wireguard-config-secret
|
||||||
|
secret:
|
||||||
|
secretName: wireguard-config-secret
|
||||||
12
qbittorrent/dns-endpoint.yaml
Normal file
12
qbittorrent/dns-endpoint.yaml
Normal file
@@ -0,0 +1,12 @@
|
|||||||
|
apiVersion: externaldns.k8s.io/v1alpha1
|
||||||
|
kind: DNSEndpoint
|
||||||
|
metadata:
|
||||||
|
name: qbittorrent.michaelthomson.dev
|
||||||
|
namespace: qbittorrent
|
||||||
|
spec:
|
||||||
|
endpoints:
|
||||||
|
- dnsName: qbittorrent.michaelthomson.dev
|
||||||
|
recordTTL: 180
|
||||||
|
recordType: CNAME
|
||||||
|
targets:
|
||||||
|
- server.michaelthomson.dev
|
||||||
10
qbittorrent/gluetun-config.yaml
Normal file
10
qbittorrent/gluetun-config.yaml
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: ConfigMap
|
||||||
|
metadata:
|
||||||
|
name: gluetun-config
|
||||||
|
namespace: qbittorrent
|
||||||
|
data:
|
||||||
|
VPN_SERVICE_PROVIDER: custom
|
||||||
|
VPN_TYPE: wireguard
|
||||||
|
VPN_PORT_FORWARDING: on
|
||||||
|
VPN_PORT_FORWARDING_PROVIDER: protonvpn
|
||||||
25
qbittorrent/ingress.yaml
Normal file
25
qbittorrent/ingress.yaml
Normal file
@@ -0,0 +1,25 @@
|
|||||||
|
apiVersion: networking.k8s.io/v1
|
||||||
|
kind: Ingress
|
||||||
|
metadata:
|
||||||
|
name: qbittorrent
|
||||||
|
namespace: qbittorrent
|
||||||
|
annotations:
|
||||||
|
traefik.ingress.kubernetes.io/router.entrypoints: websecure
|
||||||
|
traefik.ingress.kubernetes.io/router.middlewares: traefik-authentik@kubernetescrd
|
||||||
|
traefik.ingress.kubernetes.io/router.tls: "true"
|
||||||
|
spec:
|
||||||
|
rules:
|
||||||
|
- host: qbittorrent.michaelthomson.dev
|
||||||
|
http:
|
||||||
|
paths:
|
||||||
|
- pathType: ImplementationSpecific
|
||||||
|
path: /
|
||||||
|
backend:
|
||||||
|
service:
|
||||||
|
name: qbittorrent
|
||||||
|
port:
|
||||||
|
name: http
|
||||||
|
tls:
|
||||||
|
- hosts:
|
||||||
|
- qbittorrent.michaelthomson.dev
|
||||||
|
secretName: letsencrypt-wildcard-cert-michaelthomson.dev
|
||||||
12
qbittorrent/pvc-data.yaml
Normal file
12
qbittorrent/pvc-data.yaml
Normal file
@@ -0,0 +1,12 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: PersistentVolumeClaim
|
||||||
|
metadata:
|
||||||
|
name: data
|
||||||
|
namespace: qbittorrent
|
||||||
|
spec:
|
||||||
|
accessModes:
|
||||||
|
- ReadWriteOnce
|
||||||
|
storageClassName: longhorn
|
||||||
|
resources:
|
||||||
|
requests:
|
||||||
|
storage: 300Gi
|
||||||
12
qbittorrent/pvc-qbittorrent-config.yaml
Normal file
12
qbittorrent/pvc-qbittorrent-config.yaml
Normal file
@@ -0,0 +1,12 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: PersistentVolumeClaim
|
||||||
|
metadata:
|
||||||
|
name: qbittorrent-config
|
||||||
|
namespace: qbittorrent
|
||||||
|
spec:
|
||||||
|
resources:
|
||||||
|
requests:
|
||||||
|
storage: 1Gi
|
||||||
|
storageClassName: longhorn
|
||||||
|
accessModes:
|
||||||
|
- ReadWriteOnce
|
||||||
9
qbittorrent/qbittorrent-config.yaml
Normal file
9
qbittorrent/qbittorrent-config.yaml
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: ConfigMap
|
||||||
|
metadata:
|
||||||
|
name: qbittorrent-config
|
||||||
|
namespace: qbittorrent
|
||||||
|
data:
|
||||||
|
PUID: "1000"
|
||||||
|
PGID: "1000"
|
||||||
|
DOCKER_MODS: arafatamim/linuxserver-io-mod-vuetorrent
|
||||||
12
qbittorrent/service.yaml
Normal file
12
qbittorrent/service.yaml
Normal file
@@ -0,0 +1,12 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: Service
|
||||||
|
metadata:
|
||||||
|
name: qbittorrent
|
||||||
|
namespace: qbittorrent
|
||||||
|
spec:
|
||||||
|
selector:
|
||||||
|
app: qbittorrent
|
||||||
|
ports:
|
||||||
|
- port: 80
|
||||||
|
targetPort: http
|
||||||
|
name: http
|
||||||
14
qbittorrent/wireguard-config-secret.yaml
Normal file
14
qbittorrent/wireguard-config-secret.yaml
Normal file
@@ -0,0 +1,14 @@
|
|||||||
|
kind: SealedSecret
|
||||||
|
apiVersion: bitnami.com/v1alpha1
|
||||||
|
metadata:
|
||||||
|
name: wireguard-config-secret
|
||||||
|
namespace: qbittorrent
|
||||||
|
creationTimestamp:
|
||||||
|
spec:
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
name: wireguard-config-secret
|
||||||
|
namespace: qbittorrent
|
||||||
|
creationTimestamp:
|
||||||
|
encryptedData:
|
||||||
|
wg0.conf: AgDdF/rwKFANlByNG4But/CCqBC0BlQECdh4KartOeFaraA5EdqTo3G59q5uaC3nPmtyWFrzisi4nHORJc4rLDnhkg4l183WA4uVkry7KX8clO5yxZ5MeufnOjS/Mus81ckf1D+KWwUz1Z+N5N6kEa65bcnX3umqAc+i9dzjP0Ns+1eTVHwsSKJB+sbaDCN4+EeTjSYPfu3or52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