Permalink
Browse files

Updated readme's

  • Loading branch information...
1 parent 9236809 commit 5d1424e7bdbf626d7b0be6370a70dbb20aa80402 @unwin unwin committed Feb 20, 2014
Showing with 128 additions and 57 deletions.
  1. +8 −57 README
  2. +73 −0 README.OOI_hosted_VM
  3. +10 −0 README.OOI_virtualbox_VM
  4. +37 −0 README.postgres_setup
View
65 README
@@ -53,9 +53,11 @@ For Mac, use homebrew
https://confluence.oceanobservatories.org/display/CIDev/Postgres+Datastore
https://confluence.oceanobservatories.org/display/CIDev/M112+Geospatial+Search
-- Optional: Install CouchDB (not needed if running with PostgreSQL)
-
- > brew install couchdb
+ As user postgres:
+ > createuser -s ion
+ > echo "create database ion;" | psql
+ > echo "grant all on database ion to ion;" | psql
+ > echo "alter user ion with password 'ion';" | psql
- Install libgswteos-10 for marine science calculations
> brew tap lukecampbell/homebrew-libgswteos
@@ -146,54 +148,6 @@ Note: See the New Developer Tutorial for automatic start using supervisord
> sudo sbin/rabbitmq-server
-ELASTICSEARCH (SEARCH ENGINE) - not needed when running with PostgreSQL:
-
- ------------
- Installation
- ------------
-
- Installation is performed with a script which downloads the file from
- github, extracts the contents to the INSTALL_DIR and installs the correct
- version of the plugins.
- > bash scripts/install_es.sh
- Note: Works on both Mac and (Untested) Linux. This installs ElasticSearch
- to /usr/local/elasticsearch-$(VERSION)/ by default and can be overridden
- with the INSTALL_DIR environment variable
- e.g. > INSTALL_DIR=/opt/elasticsearch bash scripts/install_es.sh
-
- ---------------------
- Running ElasticSearch
- ---------------------
-
- After ElasticSearch has been installed it can be started in foreground mode
- or daemon mode. Assuming that the install directory was /usr/local
- Foreground mode:
- > /usr/local/elasticsearch-0.18.7/bin/elasticsearch -f
-
- Daemon mode:
- > /usr/local/elasticsearch-0.18.7/bin/elasticsearch
-
- ElasticSearch is an instance of the JVM with the ElasticSearch cluster node,
- each node is equivalent to one JVM instance running ElasticSearch.
- Additional nodes means more instances of the JVM running ElasticSearch. The
- JVM minimum heap and maximum heap size and performance flags can be changed
- in the script /usr/local/elasticsearch-0.18.7/bin/elasticsearch which is
- strongly recommended for production.
-
- To install the ElasticSearch-Head plugin which provides a graphical
- interface for browsing and viewing the contents
- of the engine run:
- > bash scripts/install_es.sh -h
-
- ---------------------------------
- Viewing ElasticSearch Graphically
- ---------------------------------
-
- If the ElasticSearch-Head plugin is installed (see above) then access to the
- plugin is located at:
- http://localhost:9200/_plugin/head/
-
-
SOURCE PATH
Add the current directory to your PYTHONPATH for an easier time running
@@ -213,7 +167,6 @@ Provide local configuration overrides (e.g. broker host, debug levels) in:
List supported Pyon Capability Container arguments:
> bin/pycc --help
-
Run unit tests:
> bin/nosetests -v -a UNIT
@@ -223,18 +176,16 @@ Run smoke tests to verify sanity of the system:
Run full integration tests - this will take a long time so may be optional:
> bin/nosetests -v -a INT
-
-Start an example (bank) locally:
- > bin/pycc --rel res/deploy/examples/bank_complete.yml
- Note: It does not do anything but start a service. You need a client to trigger actions.
-
Start development instance of the ION system with all services:
> bin/pycc --rel res/deploy/r2deploy.yml
TROUBLESHOOTING
===============
+To reset the system use:
+ > bin/pycc -X -fc -bc
+
Outdated *.pyc files can causes your
tests to fail unexpectedly. Do an ant clean and try again.
> ant clean
View
@@ -0,0 +1,73 @@
+The OOI hosted VM image comes with a demo account pre-installed with
+coi-services and ion-ux under the account ooici.
+
+This should serve as a reference install to verify the VM is working as expected.
+
+To setup our environment on this VM (assuming using your own account) follow the
+following steps.
+
+1. Setup a github account:
+ https://confluence.oceanobservatories.org/display/CIDev/Github+Account+Setup
+
+2. Clone the repository:
+ git clone git@github.com:ooici/coi-services.git
+
+3. Go into the coi-services directory:
+ cd coi-services/
+
+4. Download the submodules needed by the system:
+ git submodule update --init
+
+5. Create a virtual environment to work in:
+ mkvirtualenv --no-site-packages coi
+
+ Virtualenv for python allows a user to install packages without installing
+ them to privileged system directories. The benefit of this is that an
+ environment can be easily discarded and rebuilt without tainting the base
+ system.
+
+ The 2 key commands to know when working with virtualenv's is
+
+ mkvirtualenv -- creates a new virtual environment
+
+ workon -- loads in an existing virtual environment.
+
+6. Install 2 packages needed inside the virtual environment:
+ pip install -U setuptools==0.8
+ pip install numpy==1.7.1
+
+7. Inform the system about postgres account details by defining them in a
+ config file.
+ vi res/config/pyon.local.yml
+
+ For the ooi created VM's this file should look like:
+ system:
+ name: uidev
+ server:
+ postgresql:
+ username: ion
+ password: ion
+ admin_username: ion
+ admin_password: ion
+
+ Alternatively, it can be coppied from the ooici home directory to your
+ res/config directory by doing:
+ cp ~ooici/pyon.local.yml res/config/
+
+8. Build the system:
+ python bootstrap.py -v 2.2.0
+ bin/buildout
+ bin/generate_interfaces
+
+9. Check that you have a good install:
+ bin/nosetests -a SMOKE
+
+ If none of these tests fail/error, then it is safe to assume you have
+ a working install.
+
+10. OOI guidelines on using GIT:
+ Prior to following this guide, it is assumed you have already
+ performed:
+ git remote rename origin ooici
+
+ https://confluence.oceanobservatories.org/display/CIDev/Transition+from+Release+2.0+to+Pre-Release+3.
View
@@ -0,0 +1,10 @@
+OOI provides a virtualbox appliance image that can be ran locally.A
+
+Step 1: Create a github account:
+ https://confluence.oceanobservatories.org/display/CIDev/Github+Account+Setup
+
+Step 2: Download and configure the virtualbox image:
+ https://confluence.oceanobservatories.org/display/CIDev/VirtualBox+image
+
+Step 3: OOI guidelines on using GIT:
+ https://confluence.oceanobservatories.org/display/CIDev/Transition+from+Release+2.0+to+Pre-Release+3.0
View
@@ -0,0 +1,37 @@
+If you are running the OOI system in a custom environment or on a mac,
+it is required that postgres be correctly configured.
+
+as user postgres:
+ echo "drop user ion;" | psql
+ createuser -s ion
+ echo "create database ion;" | psql
+ echo "grant all on database ion to ion;" | psql
+ echo "alter user ion with password 'ion';" | psql
+
+This will create a superuser postgress account called ion with password ion.
+It is strongly reccomended you change the password to something much better.
+
+You can test that you have postgres correctly configured by returning to your
+own user account and running:
+ psql -U ion -h localhost -p 5432
+
+ <enter the password you used above>
+
+You should see something similar to:
+ psql (9.3.2)
+ Type "help" for help.
+
+ ion=>
+
+In order to configure coi-services to know the database connection details,
+create a file in coi-services/res/config/pyon.local.yml containing:
+ system:
+ name: uidev
+ server:
+ postgresql:
+ username: ion
+ password: ion
+ admin_username: ion
+ admin_password: ion
+
+

0 comments on commit 5d1424e

Please sign in to comment.