This commit is contained in:
1 parent
85f86545f5
commit
6fae4188fb
11 files changed
+499
No files matched your search
@@ -0,0 +1,24 @@
|
||||
---
|
||||
# yaml-language-server: $schema=https://kubernetes-schemas.pages.dev/external-secrets.io/externalsecret_v1beta1.json
|
||||
apiVersion: external-secrets.io/v1beta1
|
||||
kind: ExternalSecret
|
||||
metadata:
|
||||
name: &name plex
|
||||
spec:
|
||||
target:
|
||||
name: *name
|
||||
deletionPolicy: Delete
|
||||
template:
|
||||
type: Opaque
|
||||
data:
|
||||
# App
|
||||
PLEX_CLAIM: "{{ .PLEX_CLAIM }}"
|
||||
data:
|
||||
- secretKey: PLEX_CLAIM
|
||||
sourceRef:
|
||||
storeRef:
|
||||
name: bitwarden-login
|
||||
kind: ClusterSecretStore
|
||||
remoteRef:
|
||||
key: &secretApiKey 8406f7ea-46b0-42ed-bcae-a83984d7b6ae
|
||||
property: password
|
||||
@@ -0,0 +1,163 @@
|
||||
---
|
||||
# yaml-language-server: $schema=https://kubernetes-schemas.pages.dev/helm.toolkit.fluxcd.io/helmrelease_v2.json
|
||||
apiVersion: helm.toolkit.fluxcd.io/v2
|
||||
kind: HelmRelease
|
||||
metadata:
|
||||
name: &app plex
|
||||
spec:
|
||||
interval: 30m
|
||||
chart:
|
||||
spec:
|
||||
chart: app-template
|
||||
version: 3.5.1
|
||||
sourceRef:
|
||||
kind: HelmRepository
|
||||
name: bjw-s
|
||||
namespace: flux-system
|
||||
install:
|
||||
remediation:
|
||||
retries: 3
|
||||
upgrade:
|
||||
cleanupOnFail: true
|
||||
remediation:
|
||||
strategy: rollback
|
||||
retries: 3
|
||||
values:
|
||||
controllers:
|
||||
plex:
|
||||
annotations:
|
||||
reloader.stakater.com/auto: "true"
|
||||
containers:
|
||||
app:
|
||||
image:
|
||||
repository: ghcr.io/onedr0p/plex
|
||||
tag: rolling@sha256:47c6f3d85f4e739210860934a0bb24126170fa2f6a602fb909467f17a035c311
|
||||
env:
|
||||
TZ: "${TIMEZONE}"
|
||||
ALLOWED_NETWORKS: "${LAN_CIDR},${CLUSTER_CIDR},${SERVICE_CIDR}"
|
||||
PLEX_ADVERTISE_URL: "http://${SVC_PLEX_ADDR}:32400,https://plex.${SECRET_INTERNAO_DOMAIN}"
|
||||
PLEX_PREFERENCE_1: "AllowMediaDeletion=0"
|
||||
PLEX_PREFERENCE_2: "EnableIPv6=0"
|
||||
PLEX_PREFERENCE_3: "FriendlyName=Runnels"
|
||||
PLEX_PREFERENCE_4: "LanNetworksBandwidth=${LAN_CIDR}"
|
||||
# NVIDIA_VISIBLE_DEVICES: "all"
|
||||
# NVIDIA_DRIVER_CAPABILITIES: "all"
|
||||
# HARDWARE_DEVICE_PATH: "/dev/nvidia0"
|
||||
envFrom:
|
||||
- secretRef:
|
||||
name: *app
|
||||
probes:
|
||||
liveness: &probes
|
||||
enabled: true
|
||||
custom: true
|
||||
spec:
|
||||
httpGet:
|
||||
path: /identity
|
||||
port: &port 32400
|
||||
initialDelaySeconds: 0
|
||||
periodSeconds: 10
|
||||
timeoutSeconds: 1
|
||||
failureThreshold: 3
|
||||
readiness: *probes
|
||||
resources:
|
||||
requests:
|
||||
cpu: 50m
|
||||
memory: 512Mi
|
||||
# nvidia.com/gpu: 1
|
||||
limits:
|
||||
# nvidia.com/gpu: 1
|
||||
memory: 4Gi
|
||||
securityContext:
|
||||
allowPrivilegeEscalation: false
|
||||
readOnlyRootFilesystem: true
|
||||
capabilities: { drop: ["ALL"] }
|
||||
defaultPodOptions:
|
||||
# runtimeClassName: nvidia
|
||||
# nodeSelector:
|
||||
# nvidia.feature.node.kubernetes.io/gpu: "true"
|
||||
securityContext:
|
||||
runAsNonRoot: true
|
||||
runAsUser: 1000
|
||||
runAsGroup: 1000
|
||||
fsGroup: 1000
|
||||
fsGroupChangePolicy: OnRootMismatch
|
||||
seccompProfile: { type: RuntimeDefault }
|
||||
service:
|
||||
app:
|
||||
controller: *app
|
||||
type: LoadBalancer
|
||||
annotations:
|
||||
io.cilium/lb-ipam-ips: ${SVC_PLEX_ADDR}
|
||||
ports:
|
||||
http:
|
||||
port: *port
|
||||
ingress:
|
||||
app:
|
||||
className: internal
|
||||
# annotations:
|
||||
# external-dns.alpha.kubernetes.io/target: external.${SECRET_DOMAIN}
|
||||
# gethomepage.dev/enabled: "true"
|
||||
# gethomepage.dev/group: Media
|
||||
# gethomepage.dev/name: Plex
|
||||
# gethomepage.dev/icon: plex
|
||||
# gethomepage.dev/description: Media Player
|
||||
# gethomepage.dev/widget.type: plex
|
||||
# gethomepage.dev/widget.url: http://plex.media:32400
|
||||
# gethomepage.dev/widget.key: "{{ `{{HOMEPAGE_VAR_PLEX_TOKEN}}` }}"
|
||||
# nginx.ingress.kubernetes.io/backend-protocol: "HTTPS"
|
||||
# nginx.ingress.kubernetes.io/configuration-snippet: ${THEME_PARK_SNIPPET}
|
||||
hosts:
|
||||
- host: "{{ .Release.Name }}.${SECRET_INTERNAL_DOMAIN}"
|
||||
paths:
|
||||
- path: /
|
||||
service:
|
||||
identifier: app
|
||||
port: http
|
||||
persistence:
|
||||
config:
|
||||
enabled: true
|
||||
type: nfs
|
||||
server: 192.168.1.68
|
||||
path: /mnt/user/k3s/config/plex
|
||||
cache:
|
||||
storageClass: openebs-hostpath
|
||||
accessMode: ReadWriteOnce
|
||||
size: 10Gi
|
||||
globalMounts:
|
||||
- path: "/config/Library/Application Support/Plex Media Server/Cache"
|
||||
tmp:
|
||||
type: emptyDir
|
||||
transcode:
|
||||
type: emptyDir
|
||||
movies:
|
||||
enabled: true
|
||||
type: nfs
|
||||
server: 192.168.1.68
|
||||
path: /mnt/user/movies
|
||||
globalMounts:
|
||||
- path: /media/movies
|
||||
music:
|
||||
enabled: true
|
||||
type: nfs
|
||||
server: 192.168.1.68
|
||||
path: /mnt/user/music
|
||||
globalMounts:
|
||||
- path: /media/music
|
||||
pictures:
|
||||
enabled: true
|
||||
type: nfs
|
||||
server: 192.168.1.68
|
||||
path: /mnt/user/photos/original
|
||||
globalMounts:
|
||||
- path: /media/photos
|
||||
tv:
|
||||
enabled: true
|
||||
type: nfs
|
||||
server: 192.168.1.68
|
||||
path: /mnt/user/shows
|
||||
globalMounts:
|
||||
- path: /media/tv
|
||||
# videos:
|
||||
# existingClaim: cifs-videos
|
||||
# globalMounts:
|
||||
# - path: /media/videos
|
||||
@@ -0,0 +1,8 @@
|
||||
---
|
||||
# yaml-language-server: $schema=https://json.schemastore.org/kustomization
|
||||
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||
kind: Kustomization
|
||||
resources:
|
||||
- ./externalsecret.yaml
|
||||
- ./helmrelease.yaml
|
||||
# - ../../../../templates/gatus/external
|
||||
Reference in new issue
Block a user