diff --git a/apps/charts/zerobyte/Chart.yaml b/apps/charts/zerobyte/Chart.yaml new file mode 100644 index 0000000..ca197f4 --- /dev/null +++ b/apps/charts/zerobyte/Chart.yaml @@ -0,0 +1,3 @@ +apiVersion: v2 +version: 1.0.0 +name: zerobyte diff --git a/apps/charts/zerobyte/templates/deployment.yaml b/apps/charts/zerobyte/templates/deployment.yaml new file mode 100644 index 0000000..3f19e3b --- /dev/null +++ b/apps/charts/zerobyte/templates/deployment.yaml @@ -0,0 +1,48 @@ +apiVersion: apps/v1 +kind: Deployment +metadata: + name: "{{ .Release.Name }}" +spec: + strategy: + type: Recreate + replicas: 1 + selector: + matchLabels: + app: "{{ .Release.Name }}" + template: + metadata: + labels: + app: "{{ .Release.Name }}" + spec: + containers: + - name: "{{ .Release.Name }}" + image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}" + imagePullPolicy: "{{ .Values.image.pullPolicy }}" + ports: + - name: http + containerPort: 4096 + protocol: TCP + livenessProbe: + tcpSocket: + port: http + readinessProbe: + tcpSocket: + port: http + volumeMounts: + - mountPath: /var/lib/zerobyte + name: config + - mountPath: /backups + name: backups + - mountPath: /data/pictures + name: pictures + readOnly: true + volumes: + - name: config + persistentVolumeClaim: + claimName: "{{ .Release.Name }}-config" + - name: backups + persistentVolumeClaim: + claimName: backups + - name: pictures + persistentVolumeClaim: + claimName: pictures diff --git a/apps/charts/zerobyte/templates/http-service.yaml b/apps/charts/zerobyte/templates/http-service.yaml new file mode 100644 index 0000000..15b1989 --- /dev/null +++ b/apps/charts/zerobyte/templates/http-service.yaml @@ -0,0 +1,11 @@ +apiVersion: homelab.mortenolsen.pro/v1 +kind: HttpService +metadata: + name: "{{ .Release.Name }}" +spec: + environment: "{{ .Values.globals.environment }}" + subdomain: "{{ .Values.subdomain }}" + destination: + host: "{{ .Release.Name }}" + port: + number: 80 diff --git a/apps/charts/zerobyte/templates/pvc.yaml b/apps/charts/zerobyte/templates/pvc.yaml new file mode 100644 index 0000000..8cbd0b4 --- /dev/null +++ b/apps/charts/zerobyte/templates/pvc.yaml @@ -0,0 +1,11 @@ +kind: PersistentVolumeClaim +apiVersion: v1 +metadata: + name: "{{ .Release.Name }}-config" +spec: + accessModes: + - "ReadWriteOnce" + resources: + requests: + storage: "1Gi" + storageClassName: "{{ .Values.globals.environment }}" diff --git a/apps/charts/zerobyte/templates/service.yaml b/apps/charts/zerobyte/templates/service.yaml new file mode 100644 index 0000000..ddc01de --- /dev/null +++ b/apps/charts/zerobyte/templates/service.yaml @@ -0,0 +1,15 @@ +apiVersion: v1 +kind: Service +metadata: + name: "{{ .Release.Name }}" + labels: + app: "{{ .Release.Name }}" +spec: + type: ClusterIP + ports: + - port: 80 + targetPort: 4096 + protocol: TCP + name: http + selector: + app: "{{ .Release.Name }}" diff --git a/apps/charts/zerobyte/values.yaml b/apps/charts/zerobyte/values.yaml new file mode 100644 index 0000000..e2d0de1 --- /dev/null +++ b/apps/charts/zerobyte/values.yaml @@ -0,0 +1,5 @@ +image: + repository: ghcr.io/nicotsx/zerobyte + tag: v0.15 + pullPolicy: IfNotPresent +subdomain: zerobyte