105 lines
2.1 KiB
YAML
105 lines
2.1 KiB
YAML
|
---
|
||
|
apiVersion: networking.k8s.io/v1
|
||
|
kind: Ingress
|
||
|
metadata:
|
||
|
name: audiobookshelf
|
||
|
namespace: audiobookshelf
|
||
|
spec:
|
||
|
ingressClassName: haproxy
|
||
|
rules:
|
||
|
- host: audiobooks.strudelline.net
|
||
|
http:
|
||
|
paths:
|
||
|
- path: /
|
||
|
pathType: Prefix
|
||
|
backend:
|
||
|
service:
|
||
|
name: audiobookshelf
|
||
|
port:
|
||
|
number: 80
|
||
|
---
|
||
|
apiVersion: v1
|
||
|
kind: PersistentVolumeClaim
|
||
|
metadata:
|
||
|
name: audiobookshelf-data
|
||
|
namespace: audiobookshelf
|
||
|
spec:
|
||
|
accessModes:
|
||
|
- ReadWriteOnce
|
||
|
resources:
|
||
|
requests:
|
||
|
storage: 1Gi
|
||
|
storageClassName: ssd
|
||
|
volumeMode: Filesystem
|
||
|
---
|
||
|
apiVersion: apps/v1
|
||
|
kind: Deployment
|
||
|
metadata:
|
||
|
namespace: audiobookshelf
|
||
|
name: audiobookshelf
|
||
|
spec:
|
||
|
replicas: 1
|
||
|
selector:
|
||
|
matchLabels:
|
||
|
app: audiobookshelf
|
||
|
strategy:
|
||
|
type: Recreate
|
||
|
template:
|
||
|
metadata:
|
||
|
labels:
|
||
|
app: audiobookshelf
|
||
|
spec:
|
||
|
terminationGracePeriodSeconds: 0
|
||
|
restartPolicy: Always
|
||
|
volumes:
|
||
|
- name: data
|
||
|
persistentVolumeClaim:
|
||
|
claimName: audiobookshelf-data
|
||
|
- name: podcasts
|
||
|
nfs:
|
||
|
server: 172.16.18.1
|
||
|
path: /volume1/podcasts
|
||
|
- name: audiobooks
|
||
|
nfs:
|
||
|
server: 172.16.18.1
|
||
|
path: /volume1/audiobooks
|
||
|
containers:
|
||
|
- name: audiobookshelf
|
||
|
image: ghcr.io/advplyr/audiobookshelf:2.4.4
|
||
|
env: []
|
||
|
volumeMounts:
|
||
|
- mountPath: /audiobooks
|
||
|
name: audiobooks
|
||
|
- mountPath: /podcasts
|
||
|
name: podcasts
|
||
|
- mountPath: /config
|
||
|
name: data
|
||
|
subPath: config
|
||
|
- mountPath: /metadata
|
||
|
name: data
|
||
|
subPath: metadata
|
||
|
#securityContext:
|
||
|
# capabilities:
|
||
|
# add: ["NET_ADMIN","SYS_TIME"]
|
||
|
---
|
||
|
apiVersion: v1
|
||
|
kind: Service
|
||
|
metadata:
|
||
|
labels:
|
||
|
app: audiobookshelf
|
||
|
name: audiobookshelf
|
||
|
namespace: audiobookshelf
|
||
|
spec:
|
||
|
ipFamilies:
|
||
|
- IPv4
|
||
|
ipFamilyPolicy: SingleStack
|
||
|
ports:
|
||
|
- name: audiobookshelf
|
||
|
port: 80
|
||
|
protocol: TCP
|
||
|
targetPort: 80
|
||
|
selector:
|
||
|
app: audiobookshelf
|
||
|
sessionAffinity: None
|
||
|
type: ClusterIP
|