Skip to content
This repository was archived by the owner on Dec 30, 2019. It is now read-only.

install opensuse

Patrick Grimm edited this page Jul 14, 2014 · 8 revisions
  1. Install couchapp
 zypper install python-pip
 pip install couchapp
  1. Install couchdb

zypper install couchdb

  1. Install couchdb source and extract
zypper source-install couchdb
mkdir /usr/src/packages/SOURCES/apache-couchdb-1.2.0
tar -xf /usr/src/packages/SOURCES/apache-couchdb-1.2.0.tar.gz -C /usr/src/packages/SOURCES/
  1. Install geocouch make depends

zypper install erlang

export COUCH_SRC=/usr/src/packages/SOURCES/apache-couchdb-1.2.0/src/couchdb/

  1. Install geocouch

git clone https://github.com/couchbase/geocouch.git

cd geocouch

git checkout -b remotes/origin/couchdb1.2.x

git checkout couchdb1.2.x

make

cp etc/couchdb/default.d/geocouch.ini /etc/couchdb/default.d/

cp share/www/script/test/* /usr/share/couchdb/www/script/test/

mkdir -p /usr/local/ebin/

cp -a ebin/* /usr/local/ebin/

  1. Add erlang PATH

nano /etc/init.d/couchdb

export ERL_FLAGS="-pa /usr/local/ebin"

  1. Add Vhost to simplify the url

nano /etc/couchdb/local.ini

[vhosts]

map.pberg.freifunk.net = /openwifimap/_design/openwifimap/_rewrite

  1. Restart the couchdb server

service couchdb restart

cat /var/log/couchdb/couchdb.stderr

  1. Webserver config

  2. nginx vhost config server { listen [::]:80; server_name couch.pberg.freifunk.net; access_log /var/log/nginx/couch.pberg.freifunk.net.access.log main; error_log /var/log/nginx/couch.pberg.freifunk.net.error.log info; location / { proxy_pass http://127.0.0.1:5984; proxy_redirect off; proxy_set_header Host $host; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; } }

  3. lighttpd vhost config $HTTP["host"] == "map.pberg.freifunk.net" { var.server_name = "map.pberg.freifunk.net" server.name = server_name server.document-root = "/srv/www/vhosts/pberg" proxy.server = ( "/" => (("host" => "127.0.0.1", "port" => 5984)) ) accesslog.filename = log_root + "/" + server_name + "/access.log" }

Clone this wiki locally