158 lines
3.6 KiB
YAML
158 lines
3.6 KiB
YAML
---
|
|
# Source: kiwix/templates/persistent-volume.yaml
|
|
apiVersion: v1
|
|
kind: PersistentVolume
|
|
metadata:
|
|
name: kiwix-nfs-storage
|
|
namespace: kiwix
|
|
labels:
|
|
app.kubernetes.io/name: kiwix-nfs-storage
|
|
app.kubernetes.io/instance: kiwix
|
|
app.kubernetes.io/part-of: kiwix
|
|
spec:
|
|
persistentVolumeReclaimPolicy: Retain
|
|
storageClassName: nfs-client
|
|
capacity:
|
|
storage: 1Gi
|
|
accessModes:
|
|
- ReadWriteMany
|
|
nfs:
|
|
path: /volume2/Storage/Kiwix
|
|
server: synologybond.alexlebens.net
|
|
mountOptions:
|
|
- vers=4
|
|
- minorversion=1
|
|
- noac
|
|
---
|
|
# Source: kiwix/templates/persistent-volume-claim.yaml
|
|
apiVersion: v1
|
|
kind: PersistentVolumeClaim
|
|
metadata:
|
|
name: kiwix-nfs-storage
|
|
namespace: kiwix
|
|
labels:
|
|
app.kubernetes.io/name: kiwix-nfs-storage
|
|
app.kubernetes.io/instance: kiwix
|
|
app.kubernetes.io/part-of: kiwix
|
|
spec:
|
|
volumeName: kiwix-nfs-storage
|
|
storageClassName: nfs-client
|
|
accessModes:
|
|
- ReadWriteMany
|
|
resources:
|
|
requests:
|
|
storage: 1Gi
|
|
---
|
|
# Source: kiwix/charts/kiwix/templates/common.yaml
|
|
apiVersion: v1
|
|
kind: Service
|
|
metadata:
|
|
name: kiwix
|
|
labels:
|
|
app.kubernetes.io/instance: kiwix
|
|
app.kubernetes.io/managed-by: Helm
|
|
app.kubernetes.io/name: kiwix
|
|
app.kubernetes.io/service: kiwix
|
|
helm.sh/chart: kiwix-4.4.0
|
|
namespace: kiwix
|
|
spec:
|
|
type: ClusterIP
|
|
ports:
|
|
- port: 80
|
|
targetPort: 8080
|
|
protocol: TCP
|
|
name: http
|
|
selector:
|
|
app.kubernetes.io/controller: main
|
|
app.kubernetes.io/instance: kiwix
|
|
app.kubernetes.io/name: kiwix
|
|
---
|
|
# Source: kiwix/charts/kiwix/templates/common.yaml
|
|
---
|
|
apiVersion: apps/v1
|
|
kind: Deployment
|
|
metadata:
|
|
name: kiwix
|
|
labels:
|
|
app.kubernetes.io/controller: main
|
|
app.kubernetes.io/instance: kiwix
|
|
app.kubernetes.io/managed-by: Helm
|
|
app.kubernetes.io/name: kiwix
|
|
helm.sh/chart: kiwix-4.4.0
|
|
namespace: kiwix
|
|
spec:
|
|
revisionHistoryLimit: 3
|
|
replicas: 1
|
|
strategy:
|
|
type: Recreate
|
|
selector:
|
|
matchLabels:
|
|
app.kubernetes.io/controller: main
|
|
app.kubernetes.io/name: kiwix
|
|
app.kubernetes.io/instance: kiwix
|
|
template:
|
|
metadata:
|
|
labels:
|
|
app.kubernetes.io/controller: main
|
|
app.kubernetes.io/instance: kiwix
|
|
app.kubernetes.io/name: kiwix
|
|
spec:
|
|
enableServiceLinks: false
|
|
serviceAccountName: default
|
|
automountServiceAccountToken: true
|
|
hostIPC: false
|
|
hostNetwork: false
|
|
hostPID: false
|
|
dnsPolicy: ClusterFirst
|
|
containers:
|
|
- args:
|
|
- '*.zim'
|
|
env:
|
|
- name: PORT
|
|
value: "8080"
|
|
image: ghcr.io/kiwix/kiwix-serve:3.8.0
|
|
imagePullPolicy: IfNotPresent
|
|
name: main
|
|
resources:
|
|
requests:
|
|
cpu: 50m
|
|
memory: 512Mi
|
|
volumeMounts:
|
|
- mountPath: /data
|
|
name: media
|
|
readOnly: true
|
|
volumes:
|
|
- name: media
|
|
persistentVolumeClaim:
|
|
claimName: kiwix-nfs-storage
|
|
---
|
|
# Source: kiwix/templates/http-route.yaml
|
|
apiVersion: gateway.networking.k8s.io/v1
|
|
kind: HTTPRoute
|
|
metadata:
|
|
name: http-route-kiwix
|
|
namespace: kiwix
|
|
labels:
|
|
app.kubernetes.io/name: http-route-kiwix
|
|
app.kubernetes.io/instance: kiwix
|
|
app.kubernetes.io/part-of: kiwix
|
|
spec:
|
|
parentRefs:
|
|
- group: gateway.networking.k8s.io
|
|
kind: Gateway
|
|
name: traefik-gateway
|
|
namespace: traefik
|
|
hostnames:
|
|
- kiwix.alexlebens.net
|
|
rules:
|
|
- matches:
|
|
- path:
|
|
type: PathPrefix
|
|
value: /
|
|
backendRefs:
|
|
- group: ''
|
|
kind: Service
|
|
name: kiwix
|
|
port: 80
|
|
weight: 100
|