diff --git a/cluster/apps/invidious/invidious-db.yml b/cluster/apps/invidious/invidious-db.yml index f93499c..0dc7ed0 100644 --- a/cluster/apps/invidious/invidious-db.yml +++ b/cluster/apps/invidious/invidious-db.yml @@ -14,6 +14,17 @@ spec: labels: app: invidious-db spec: + initContainers: + - name: clean-db-dir + image: busybox + command: + - sh + - -c + - | + rm -rf /var/lib/postgresql/data/lost+found + volumeMounts: + - name: postgres-data + mountPath: /var/lib/postgresql/data containers: - name: postgres image: postgres:14 @@ -61,4 +72,4 @@ spec: volumes: - name: postgres-data persistentVolumeClaim: - claimName: longhorn-invidious-config \ No newline at end of file + claimName: longhorn-invidious-config