Skip to content

Instantly share code, notes, and snippets.

@craigminihan
Last active January 30, 2017 15:50
Show Gist options
  • Save craigminihan/3befd5a414847ccbe66f to your computer and use it in GitHub Desktop.
Save craigminihan/3befd5a414847ccbe66f to your computer and use it in GitHub Desktop.
Script for installing CouchDB 1.6 on Debian 8
apt-get install -y erlang-nox erlang-dev
apt-get install -y libnspr4 libnspr4-0d libnspr4-dev libcurl4-openssl-dev curl libicu-dev
apt-get install -y libmozjs185-1.0 libmozjs185-dev
wget ftp://ftp.mirrorservice.org/sites/ftp.apache.org/couchdb/source/1.6.1/apache-couchdb-1.6.1.tar.gz
tar xzf apache-couchdb-1.6.1.tar.gz
cd apache-couchdb-1.6.1
./configure --prefix=/usr/local --with-js-lib=/usr/lib --with-js-include=/usr/include/mozjs --enable-init
make
make install
useradd -d /var/lib/couchdb couchdb
mkdir -p /usr/local/{lib,etc}/couchdb /usr/local/var/{lib,log,run}/couchdb /var/lib/couchdb
chmod -R g+rw /usr/local/{lib,etc}/couchdb /usr/local/var/{lib,log,run}/couchdb
chown -R couchdb:couchdb /usr/local/{lib,etc}/couchdb /usr/local/var/{lib,log,run}/couchdb
ln -s /usr/local/etc/init.d/couchdb /etc/init.d/couchdb
/etc/init.d/couchdb start
update-rc.d couchdb defaults
@craigminihan
Copy link
Author

craigminihan commented Jan 6, 2017

Assumes that GNU Make, GCC and other build tools are already present. Run as root or sudo the lines requiring elevation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment