CouchDB: Unterschied zwischen den Versionen

Aus Hostsharing Wiki
Zur Navigation springen Zur Suche springen
(monitrc)
Zeile 13: Zeile 13:
   cd ..
   cd ..
   rm -rf apache-couchdb-3.1.0*
   rm -rf apache-couchdb-3.1.0*
== Startskript ==
xyz00-couchdb@h93:~$ cat couchdb/bin/couchdb.sh
  #!/bin/bash
  export ERL_EPMD_ADDRESS=127.0.0.1
  export ERL_EPMD_PORT=34369
  export HOME=/home/pacs/xyz00/users/couchdb
  export COUCHDB_BASE=$HOME/couchdb
  exec $COUCHDB_BASE/bin/couchdb > $COUCHDB_BASE/var/log/couchdb.log 2>&1 &
  echo $! > $COUCHDB_BASE/var/couchdb.pid


== Monit ==
== Monit ==

Version vom 13. August 2020, 13:43 Uhr

CouchDB

Mit Debian Buster wird CouchDB nicht mehr als Debian Paket auf allen unseren Managed Servern installiert sein.

Ein paar Notizen zum Selbstbau:

 wget https://downloads.apache.org/couchdb/source/3.1.0/apache-couchdb-3.1.0.tar.gz
 tar xzf apache-couchdb-3.1.0.tar.gz 
 cd apache-couchdb-3.1.0
 ./configure -c --spidermonkey-version 60
 make release
 mv rel/couchdb ..
 cd ..
 rm -rf apache-couchdb-3.1.0*

Startskript

xyz00-couchdb@h93:~$ cat couchdb/bin/couchdb.sh

 #!/bin/bash
 export ERL_EPMD_ADDRESS=127.0.0.1
 export ERL_EPMD_PORT=34369
 export HOME=/home/pacs/xyz00/users/couchdb
 export COUCHDB_BASE=$HOME/couchdb
 exec $COUCHDB_BASE/bin/couchdb > $COUCHDB_BASE/var/log/couchdb.log 2>&1 &
 echo $! > $COUCHDB_BASE/var/couchdb.pid

Monit

 xyz00-couchdb@h00:~$ cat .monitrc 
 set daemon 60 with start delay 120
 set logfile /home/pacs/xyz00/users/couchdb/monit/var/monit.log
 set idfile /home/pacs/xyz00/users/couchdb/monit/var/monit.id
 set statefile /home/pacs/xyz00/users/couchdb/monit/var/monit.state
 set mailserver localhost
 set mail-format { from: monit@xyz00.hostsharing.net }
 set alert xyz00@h93.hostsharing.net
 set httpd port 38008 address localhost
     allow couchdbadmin:chohNeub0Upie9foo3efieme
 check process couchdb with pidfile /home/pacs/xyz00/users/couchdb/couchdb/var/couchdb.pid
     start program "/home/pacs/xyz00/users/couchdb/couchdb/bin/couchdb.sh"
     stop program "/bin/bash -c '/bin/kill $( cat /home/pacs/xyz00/users/couchdb/couchdb/var/couchdb.pid )'"