Prerequisites: - None - External source of information: - Video: How to install and configure CouchDB 1.3.0 onto ubuntu desktop Step 1. Install all necessary Build-tools/Dependencies before building-from-source by running the below commands in the terminal: $ sudo apt-get update $ sudo apt-get build-dep erlang $ sudo apt-get build-dep couchdb $ sudo apt-get install libicu-dev libcurl4-gnutls-dev $ sudo apt-get install automake autoconf libtool help2man $ sudo apt-get install libmozjs-dev $ sudo apt-get install libcurl4-openssl-dev $ sudo apt-get install openssl libssl-dev Step 2. Now, install the latest Erlang from Ubuntu Software Center: $ sudo apt-get install erlang Step 3. Now, build & install the CouchDB from source-code, as follows: A. Download CouchDB source-code, for e.g. from the below site: - http://www.nic.funet.fi/pub/mirrors/apache.org/couchdb/source/1.3.1/apache-couchdb-1.3.1.tar.gz B. Unzip the above downloaded source code, for example to: ~/Programs/CouchDB/ C. Build & install from source-code by running the below commands: $ cd ~/Programs/CouchDB/apache-couchdb-1.3.1 $ ./configure $ make && sudo make install $ make clean $ make distclean Step 4. Setup the new installation of CouchDB: A. Setting up CouchDB user 1. Add a new CouchDB user: $ sudo adduser --home /usr/local/var/lib/couchdb --shell /bin/bash couchdb Full Name []: couch_user Room Number []: Work Phone []: Other []: couch_admin 2. Give above user rights to run CouchDB: $ sudo chown -R couchdb: /usr/local/var/lib/couchdb /usr/local/var/log/couchdb /usr/local/var/run/couchdb /usr/local/etc/couchdb $ sudo ln -s /usr/local/etc/init.d/couchdb /etc/init.d/couchdb B. Test: Start & Stop CouchDB: $ sudo service couchdb start Now, in the browser, open http://localhost:5984/ $ sudo service couchdb stop C. Configure CouchDB's port & ip address bindings: $ sudo gedit /usr/local/etc/couchdb/local.ini Now, modify the below lines: From: [httpd] ;port = 5984 ;bind_address = 127.0.0.1 To: [httpd] ;port = 5984 ;bind_address = 0.0.0.0 $ sudo gedit /usr/local/etc/couchdb/default.ini Now, modify the below lines: From: [httpd] port = 5984 bind_address = 127.0.0.1 To: [httpd] port = 5984 bind_address = 0.0.0.0 D. Admin account & installation verification using CouchDB's front-end: 1. Run in terminal: $ sudo service couchdb start 2. Create an admin user: i. Now, in the browser, open http://localhost:5984/_utils/ ii. Click on Login (link is on the right-bottom corner) and type the below details to the field & press create: Username: admin Password: 'Your_choice' 3. Verify this new installation: i. In-order to verify the new installation, clicking the following link on the CouchDB's front-end => 'Verify Installation' (present on the right-hand side). And now you need to again click on the link => 'Verify Your Installation' (present on the left-hand side). Therefore, you will be prompted this message => 'Your installation looks fine. Time to Relax.', this mean that your CouchDB installation was successful. ii. Now, delete the below databases created during this installation-verification, by clicking on 'Overview' link (right-top corner): a) test_suite_db b) test_suite_db2 Step 5. Launching CouchDB on your development machine: Add a launcher to your xfce4-panel in-order to Start CouchDB, with the below command: - gksudo service couchdb start Note! Optionally you can select 'Run in terminal' in-order to view the startup logs.
0 Comments
|
AuthorCategories
All
Archives
January 2019
|