Moving to couch3.
We pre-populate debconf for unattended installs when provisioning servers. Something like...
echo "couchdb couchdb/mode select standalone
couchdb couchdb/adminpass password <somepass>
couchdb couchdb/adminpass_again password <somepass>
couchdb couchdb/bindaddress string 127.0.0.1
couchdb couchdb/nodename string couchdb@localhost
couchdb couchdb/postrm_remove_databases boolean false
couchdb couchdb/cookie string <somecookie>
" | debconf-set-selections
followed by
DEBIAN_FRONTEND=noninteractive apt-get install -y couchdb
However when starting up couchdb we get the following:
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
No Admin Account Found, aborting startup.
Please configure an admin account in your local.ini file.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
However if we clear the debconf values and do a manual interactive install of couchdb, the admin account is properly set and couchdb starts up without issue.
apt-get remove couchdb
apt-get install debconf-utils
echo PURGE | debconf-communicate couchdb
debconf-get-selections | grep -E '^couchdb'
apt-get install couchdb
Is there a way we can utilize debconf preseed to ensure the admin is created?
I know I can also set the password in a local ini and couch will salt/hash it on next startup...however we would like to use debconf if possible.