Skip to content

CouchDB password management

CouchDB credentials are stored in the common ConfigMap. Two fields must be updated together: couchdb_admin_password and couchdb_connection (which embeds the password in the URL).

No manual CouchDB API command is required — the startup script automatically applies the new credentials to CouchDB when the pod restarts.

Edit configmaps.yaml with the new password in both fields:

couchdb_admin_password: "New-password1"
couchdb_connection: "http://admin:New-password1@couchdb:5984"
Terminal window
kubectl apply -f configmaps.yaml -n demo-metalsoft

CouchDB must restart first so it picks up and applies the new credentials before other services attempt to reconnect.

Terminal window
kubectl -n demo-metalsoft rollout restart deployment couchdb
kubectl -n demo-metalsoft rollout status deployment couchdb

Restart all deployments that connect to CouchDB so they pick up the updated couchdb_connection value:

Terminal window
cd manifests/
grep -l "couchdb_connection" *-deployment.yaml 2>/dev/null | sed 's/-deployment\.yaml//g' | while read z
do kubectl -n demo-metalsoft rollout restart deployment $z
done