From dc6e8384d50561bea2965f9ff51ebbef38629f09 Mon Sep 17 00:00:00 2001 From: funman300 Date: Mon, 18 May 2026 12:58:55 -0700 Subject: [PATCH] fix(obsidian-livesync): copy configmap via init container to avoid unchownable subPath bind-mount --- apps/obsidian-livesync/couchdb-deployment.yaml | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/apps/obsidian-livesync/couchdb-deployment.yaml b/apps/obsidian-livesync/couchdb-deployment.yaml index 91f494f..7f525b2 100644 --- a/apps/obsidian-livesync/couchdb-deployment.yaml +++ b/apps/obsidian-livesync/couchdb-deployment.yaml @@ -15,6 +15,15 @@ spec: labels: app: couchdb spec: + initContainers: + - name: config-copy + image: busybox + command: ["cp", "/cm/livesync.ini", "/local-d/livesync.ini"] + volumeMounts: + - name: couchdb-config + mountPath: /cm + - name: couchdb-local-d + mountPath: /local-d containers: - name: couchdb image: couchdb:3 @@ -40,9 +49,8 @@ spec: volumeMounts: - name: couchdb-data mountPath: /opt/couchdb/data - - name: couchdb-config - mountPath: /opt/couchdb/etc/local.d/livesync.ini - subPath: livesync.ini + - name: couchdb-local-d + mountPath: /opt/couchdb/etc/local.d livenessProbe: httpGet: path: /_up @@ -69,3 +77,5 @@ spec: - name: couchdb-config configMap: name: couchdb-config + - name: couchdb-local-d + emptyDir: {}