Creating an admin user via http://localhost:5984/_utils/ is impossible if the user "couchdb" has no write access to /etc/couchdb. When trying to create such a user, the webinterface will hang, constantly reloading the page, instead of creating the admin user. Reproducible: Always
Does it really need write access to /etc/couchdb, or just to the ini files contained in that directory? If the latter, the current ebuild already sets it up like that (with rw-rw-r-- for /etc/couchdb/*.ini).
I installed dev-db/couchdb-1.0.1-r1 on Sep 16th, and the testsuite as well as the create-admin-user-thing did not work.
I encountered the same problem, and found my solution at the following URL before finding this bug: http://wiki.apache.org/couchdb/Installing_on_Ubuntu The following commands fix it: # chown -R root:couchdb /etc/couchdb # chmod 664 /etc/couchdb/*.ini # chmod 775 /etc/couchdb/*.d
Created attachment 251255 [details] dev-db/couchdb-1.0.1-r2.ebuild I've found the bug in the ebuild (see following patch). I think the problem is that the wildcard expansion on fowners and fperms doesn't work because those files aren't really in /etc/couchdb at that point in src_install (they're in ${D}), and it's usually the shell that handles wildcard expansion. This works (and fixes the reported bug), but I don't know if it's the best way. - fowners root:couchdb /etc/couchdb/*.ini - fperms 660 /etc/couchdb/*.ini + fowners root:couchdb /etc/couchdb/local.ini + fowners root:couchdb /etc/couchdb/default.ini + fperms 660 /etc/couchdb/local.ini + fperms 660 /etc/couchdb/default.ini
Thanks for finding that! I think there's probably a better solution, let me ask around.
(In reply to comment #4) > - fowners root:couchdb /etc/couchdb/*.ini > - fperms 660 /etc/couchdb/*.ini > + fowners root:couchdb /etc/couchdb/local.ini > + fowners root:couchdb /etc/couchdb/default.ini > + fperms 660 /etc/couchdb/local.ini > + fperms 660 /etc/couchdb/default.ini Maybe like this? for file in "${D}"/etc/couchdb/*.ini ; do fowners root:couchdb ${file#${D}} fperms 660 ${file#${D}} done
This should be fixed in the r2 that's in the tree now, please check.