-
-
Save luisbebop/501376 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# where do you want couchdb and its deps to be installed | |
COUCHDB_PREFIX=/opt/couchdb-1.0.0 | |
# download, chmod and install | |
curl "http://dl.couchone.com/dl/20e4ab59869fc48828db075f7c000c70/couchdb-1.0.0_1-linux-x64-installer.bin" -O | |
echo "`curl http://dl.couchone.com/dl/_design/dl/_show/sha1/20e4ab59869fc48828db075f7c000c70 --silent` couchdb-1.0.0_1-linux-x64-installer.bin" | sha1sum --check - | |
chmod u+x couchdb-1.0.0_1-linux-x64-installer.bin | |
./couchdb-1.0.0_1-linux-x64-installer.bin --prefix $COUCHDB_PREFIX --mode unattended | |
# link into /etc/init.d/couchdb and setup couchdb for auto-startup | |
ln -s $COUCHDB_PREFIX/etc/init.d/couchdb /etc/init.d/couchdb | |
ln -s $COUCHDB_PREFIX/etc/init.d/couchdb /etc/default/couchdb | |
update-rc.d couchdb defaults | |
# prepare system | |
adduser --system \ | |
--home $COUCHDB_PREFIX/var/lib/couchdb \ | |
--no-create-home \ | |
--shell /bin/bash \ | |
--group --gecos \ | |
"CouchDB Administrator" couchdb | |
# ensure that our new user owns it's stuff | |
chown -R couchdb:couchdb $COUCHDB_PREFIX/{etc,var/lib,var/run,var/log}/couchdb |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hey Luis, I have a little error on line #12 and I fixed it in my gist. Just wanted you to know :)