diff --git a/charts/apps/pigeon-pod/Chart.yaml b/charts/apps/pigeon-pod/Chart.yaml new file mode 100644 index 0000000..9d3a5b9 --- /dev/null +++ b/charts/apps/pigeon-pod/Chart.yaml @@ -0,0 +1,3 @@ +apiVersion: v2 +version: 1.0.0 +name: pigeonpod diff --git a/charts/apps/pigeon-pod/templates/deployment.yaml b/charts/apps/pigeon-pod/templates/deployment.yaml new file mode 100644 index 0000000..3506fb1 --- /dev/null +++ b/charts/apps/pigeon-pod/templates/deployment.yaml @@ -0,0 +1,53 @@ +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: + hostNetwork: true + containers: + - name: "{{ .Release.Name }}" + image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}" + imagePullPolicy: "{{ .Values.image.pullPolicy }}" + ports: + - name: http + containerPort: 8080 + protocol: TCP + livenessProbe: + tcpSocket: + port: http + readinessProbe: + tcpSocket: + port: http + env: + - name: TZ + value: "{{ .Values.globals.timezone }}" + - name: PIGEON_BASE_URL + value: "https://{{ .Values.subdomain }}.{{ .Values.globals.domain }}" + - name: PIGEON_AUDIO_FILE_PATH + value: /youtube + - name: SPRING_DATASOURCE_URL + value: jdbc:sqlite:/data/pigeon-pod.db + volumeMounts: + - mountPath: /data + name: data + - mountPath: /media/youtube + name: youtube + + volumes: + - name: data + persistentVolumeClaim: + claimName: "{{ .Release.Name }}-data" + - name: youtube + persistentVolumeClaim: + claimName: youtube diff --git a/charts/apps/pigeon-pod/templates/external-http-service.yaml b/charts/apps/pigeon-pod/templates/external-http-service.yaml new file mode 100644 index 0000000..e28916d --- /dev/null +++ b/charts/apps/pigeon-pod/templates/external-http-service.yaml @@ -0,0 +1,11 @@ +apiVersion: homelab.mortenolsen.pro/v1 +kind: ExternalHttpService +metadata: + name: '{{ .Release.Name }}' +spec: + environment: '{{ .Values.globals.environment }}' + subdomain: '{{ .Values.subdomain }}' + destination: + host: '{{ .Release.Name }}.{{ .Release.Namespace }}.svc.cluster.local' + port: + number: 80 diff --git a/charts/apps/pigeon-pod/templates/http-service.yaml b/charts/apps/pigeon-pod/templates/http-service.yaml new file mode 100644 index 0000000..15b1989 --- /dev/null +++ b/charts/apps/pigeon-pod/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/charts/apps/pigeon-pod/templates/pvc.yaml b/charts/apps/pigeon-pod/templates/pvc.yaml new file mode 100644 index 0000000..bc1d0a6 --- /dev/null +++ b/charts/apps/pigeon-pod/templates/pvc.yaml @@ -0,0 +1,11 @@ +kind: PersistentVolumeClaim +apiVersion: v1 +metadata: + name: '{{ .Release.Name }}-data' +spec: + accessModes: + - 'ReadWriteOnce' + resources: + requests: + storage: '1Gi' + storageClassName: '{{ .Values.globals.environment }}' diff --git a/charts/apps/pigeon-pod/templates/service.yaml b/charts/apps/pigeon-pod/templates/service.yaml new file mode 100644 index 0000000..c2cbc23 --- /dev/null +++ b/charts/apps/pigeon-pod/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: 8080 + protocol: TCP + name: http + selector: + app: "{{ .Release.Name }}" diff --git a/charts/apps/pigeon-pod/values.yaml b/charts/apps/pigeon-pod/values.yaml new file mode 100644 index 0000000..de0c088 --- /dev/null +++ b/charts/apps/pigeon-pod/values.yaml @@ -0,0 +1,5 @@ +image: + repository: ghcr.io/aizhimou/pigeon-pod + tag: release-1.12.3 + pullPolicy: IfNotPresent +subdomain: pigeonpod diff --git a/charts/apps/volumes/values.yaml b/charts/apps/volumes/values.yaml index a477ab3..f2bcc0d 100644 --- a/charts/apps/volumes/values.yaml +++ b/charts/apps/volumes/values.yaml @@ -14,3 +14,5 @@ shares: path: /mnt/HDD/Pictures backups: path: /mnt/HDD/Backups + youtube: + path: /mnt/HDD/Youtube diff --git a/helmfile.yaml b/helmfile.yaml index 782c0ab..22ba3a3 100644 --- a/helmfile.yaml +++ b/helmfile.yaml @@ -149,6 +149,10 @@ releases: - values.yaml - name: mindsdb chart: charts/apps/mindsdb + values: + - values.yaml + - name: pigeonpod + chart: charts/apps/pigeon-pod namespace: prod values: - values.yaml