Add init container to clean PostgreSQL data directory
This commit is contained in:
@@ -14,6 +14,17 @@ spec:
|
|||||||
labels:
|
labels:
|
||||||
app: invidious-db
|
app: invidious-db
|
||||||
spec:
|
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:
|
containers:
|
||||||
- name: postgres
|
- name: postgres
|
||||||
image: postgres:14
|
image: postgres:14
|
||||||
|
|||||||
Reference in New Issue
Block a user