diff options
author | Andreas Maunz <andreas@maunz.de> | 2012-08-25 08:52:50 +0200 |
---|---|---|
committer | Andreas Maunz <andreas@maunz.de> | 2012-08-25 08:52:50 +0200 |
commit | 283cbf9c9c26d89d14736707950c52b56717e539 (patch) | |
tree | c1495511a773a34d1792a8832391eba1b2bb3da7 | |
parent | 1a1823e29b9afc0510e353374e02c00c9204cb0b (diff) | |
parent | 1568585533834220d1ea41ca0550fd2f673b8d01 (diff) |
Merge branch 'master' of github.com:opentox/opentox.github.com
4 files changed, 127 insertions, 49 deletions
diff --git a/_posts/2012-05-25-installation-issues.md b/_posts/2012-05-25-installation-issues.md index 97db7bb..ea4adb5 100644 --- a/_posts/2012-05-25-installation-issues.md +++ b/_posts/2012-05-25-installation-issues.md @@ -19,6 +19,7 @@ Proceed as follows **before installing**.: curl -L http://launchpadlibrarian.net/48177999/libgsl0-dev_1.14%2Bdfsg-1_amd64.deb > libgsl0-dev_1.14+dfsg-1_amd64.deb curl -L http://launchpadlibrarian.net/48177998/libgsl0ldbl_1.14%2Bdfsg-1_amd64.deb > libgsl0ldbl_1.14+dfsg-1_amd64.deb sudo dpkg -i libgsl0-dev_1.14+dfsg-1_amd64.deb + sudo dpkg -i libgsl0ldbl_1.14+dfsg-1_amd64.deb In the above, adjust your architecture to `i386`, if necessary (please use 64 bit software where possible). diff --git a/_posts/2012-08-09-install-opentox-development-environment.md b/_posts/2012-08-09-install-opentox-development-environment.md index ab1b0d0..160a18a 100644 --- a/_posts/2012-08-09-install-opentox-development-environment.md +++ b/_posts/2012-08-09-install-opentox-development-environment.md @@ -2,77 +2,122 @@ layout: post title: "Install opentox development environment" description: "" -category: development +category: setup tags: [deployment, installation, Ubuntu, Debian, Setup] --- {% include JB/setup %} -How To install recent opentox services on Ubuntu or Debian +Architecture overview and how to install recent opentox services on Ubuntu or Debian. -# Installation: +# Philosophy -Installation (`development` at the point of writing this = 15/08/2012) is tested with Debian 6.0.5 and should work with recent Ubuntu versions. Installer is available at [github](https://github.com/opentox/install). Please follow instruction (an internet connection is required): +The [opentox installer](https://github.com/opentox/install/tree/development) provides a [POSIX](http://en.wikipedia.org/wiki/POSIX) compatible way to prepare Debian-based systems and install ISTs OpenTox compatible web-services and library code. Please report bugs [here](http://github.com/opentox/install). + +Apart from some basic Debian packages, no action requires root access. Everything is installed in the user's home directory. Inside it, the installer prepares the base directory (referred to as `OT_PREFIX`) for OpenTox REST services and provides libraries for the installation and shell integration of services. + +Here are some more goals we had in mind when writing the installer: + +- Safe (existence of all binaries will be checked before running, apart from GNU Core Utils) +- Idempotent (multiple execution incurs no changes to the system) +- Atomic (return value of non-elementary actions asserted to be TRUE) +- Encapsulated (everything installed in OT_PREFIX) +- Logged (all non-elementary actions are logged) + +Conceptual approach: + +1. Configure the installer in config.sh, then run `install`. +2. Configure your system by adding a line to the startup file of your favorite shell (e.g. BASH with the file `~/.bashrc`) to read in `~/.opentox/opentox-ui.sh` (e.g. with `source ~/.opentox/opentox-ui.sh`), so any newly started shell will be configured. +3. Use the system, in particular by starting webservices (see below). For `bash` users, a set of tools (called `ot-tools`) is available. +4. To uninstall, simply remove the line from the startup file, that's all. To save disc space also remove directory `OT_PREFIX`. To remove also your configuration, remove `~/.opentox`. + +<br> +<br> +<hr> +<br> +<br> + +# Installation + +Installation (`development` at the point of writing this = 22/08/2012) is tested with Debian 6.0.5 and Ubuntu 11.04. Installer is available at [github](https://github.com/opentox/install). + +Before starting the installation please check if "sudo" is available (e.g. sudo ls), required for base packages. - # Check if "sudo" is available (e.g. sudo ls) # Install git - sudo apt-get install git-core - # Please add your ssh key at github via https://github.com/. - # You may add your name/email address to the local git config. - # Download the installer from github. + sudo apt-get install git + +Please add your ssh key at github via https://github.com/. You may add your name/email address to the local git config. + +Download, configure and execute the installer. + git clone git@github.com:opentox/install.git $HOME/install cd $HOME/install git checkout development - # First check config.sh + # First check config.sh with your favorite editor ./install -This installation script will prepare your system for the use of `opentox` web services, including installing necessary dependencies, `opentox` config, `raptor`, `rasqal` and `4store`. +This installation script will prepare your system for the use of `opentox` web services, including installing necessary dependencies, `opentox` config, `raptor`, `rasqal`, `rbenv`, `ruby` and `4store`. # Install opentox services - # Check OT_PREFIX in $HOME/install/config.sh - OT_PREFIX="path/to/directory" - # Download opentox-client opentox-server opentox-test algorithm dataset feature and task - for f in opentox-client opentox-server opentox-test algorithm dataset feature task; do +Load environment (general) + + . $HOME/.opentox/config/install/config.sh + . $OT_PREFIX/install/utils.sh + +Load environment (with bash): + + . $HOME/.opentox/ot-tools.sh + otconfig + +Next opentox-client and opentox-server will be downloaded and installed. + + for f in opentox-client opentox-server; do git clone "git@github.com:opentox/$f.git" $OT_PREFIX/$f cd $OT_PREFIX/$f - git checkout development - git checkout migration + git checkout development 2>/dev/null + git checkout migration 2>/dev/null done - # Install services with script (bundle) cd $OT_PREFIX/opentox-client/bin ./opentox-client-install - # This script might fail after installing ruby, please start script again. Will be fixed soon. cd $OT_PREFIX/opentox-server/bin ./opentox-server-install - cd $OT_PREFIX - for f in algorithm dataset feature task opentox-test; do - cd $OT_PREFIX/$f/bin - ./$f-install + +OpenTox services(algorithm compound dataset feature task opentox-test) and tests will be downloaded and installed. + + for f in algorithm compound dataset feature task opentox-test; do + git clone "git@github.com:opentox/$f.git" $OT_PREFIX/$f + cd $OT_PREFIX/$f + git checkout development 2>/dev/null + git checkout migration 2>/dev/null + if [ -f $OT_PREFIX/$f/bin/$f-install ]; then + cd $OT_PREFIX/$f/bin + ./$f-install + fi done - if ! cat $HOME/.opentox/config/default.rb | grep "compound">/dev/null 2>&1; then i - echo '$compound = { :uri => "http://webservices.in-silico.ch/compound" }' >> $HOME/.opentox/config/default.rb - fi -Now, `opentox` web services are downloaded, installed and configured. +At this point `opentox` web services have been downloaded, installed and configured. -# Activate and use ot-tools +# Activate and use ot-tools if you are using bash + +NOTE: ot-tools do require the use of bash shell. Add ot-tools to your .bashrc: - echo '. ~/.opentox/ot-tools.sh' >> ~/.bashrc + echo '. $HOME/.opentox/ot-tools.sh' >> ~/.bashrc # source .bashrc or restart shell All ot-tools (`otconfig`, `otstart`, `otcheck`, `otreload`, `otkill`) are available in your shell. General usage: - [otstart|otcheck|otreload|otkill] [all|algorithm|compound|dataset|feature|model|task|validation|4store] + [otstart|otcheck|otreload|otkill] [all|algorithm|compound|dataset|feature| + model|task|validation|4store] -Only `otconfig` does not need an argument, it sets the environment variables for all services. +`otconfig` is the only command not taking an argument, it sets the environment variables for all services. -Start all services with: +Start all services and the 4store backend with: otstart all -Kill all services with: +Kill all services and the 4store backend with: otkill all @@ -80,30 +125,34 @@ It is possible to manage single services (e.g. `otstart dataset` to run dataset # Access web services -The default port setting (see default config file ~/.opentox/config/default.rb): +The default port setting for the web services and the 4store backend, (see config files `~/.opentox/config/*.rb`): - Algorithm: localhost:8081/algorithm - Compound: localhost:8082/compound - Dataset: localhost:8083/dataset - Feature: localhost:8084/feature - Model: localhost:8085/model - Task: localhost:8086/task - Validation: localhost:8087/validation - 4store: localhost:8088/ +| Service | URI | +| ------ | ------ | +| -------------------- | ------------------------------------- | +| Algorithm | localhost:8081/algorithm | +| Compound | localhost:8082/compound | +| Dataset | localhost:8083/dataset | +| Feature | localhost:8084/feature | +| Model | localhost:8085/model | +| Task | localhost:8086/task | +| Validation | localhost:8087/validation | +| 4store | localhost:9088/ | -NOTE: Only installed service uris are set in the config files. Model and validation service are not available yet and an external compound services is used. +NOTE: Only installed service URIs are set in the config files. Model and validation service are not available yet. # Testing services - cp $HOME/.opentox/config/default.rb $HOME/.opentox/config/test.rb # This is a workaround, will be fixed soon. cd $OT_PREFIX/opentox-test otconfig ruby opentox-client.rb + ruby test/dataset-large.rb -The tests are running for some time and will finish with a short report: - - Finished tests in 50.728600s, 0.7885 tests/s, 3.1935 assertions/s. - 40 tests, 162 assertions, 0 failures, 0 errors, 0 skips -To test one specific service run its script (ruby [service_name].rb) located in $OT_PREFIX/opentox-test/test. +The tests take some time and finish with a short report: + + Finished tests in 43.827407s, 0.9811 tests/s, 4.4265 assertions/s. + 42 tests, 194 assertions, 2 failures, 0 errors, 0 skips + +To test one specific service, run its script (`ruby [service_name].rb`) located in `$OT_PREFIX/opentox-test/test`. diff --git a/_posts/2012-08-20-how-to-grant-gemcutter-perimssions.md b/_posts/2012-08-20-how-to-grant-gemcutter-perimssions.md new file mode 100644 index 0000000..ef951ee --- /dev/null +++ b/_posts/2012-08-20-how-to-grant-gemcutter-perimssions.md @@ -0,0 +1,12 @@ +--- +layout: post +title: "How to grant gemcutter perimssions" +description: "" +category: general +tags: [development] +--- +{% include JB/setup %} + +Grant gemcutter push permissions by creating another owner: + + gem owner -a EMAIL GEM_NAME diff --git a/_posts/2012-08-23-install-production-webservice-gems.md b/_posts/2012-08-23-install-production-webservice-gems.md new file mode 100644 index 0000000..890184f --- /dev/null +++ b/_posts/2012-08-23-install-production-webservice-gems.md @@ -0,0 +1,16 @@ +--- +layout: post +title: "Install production webservice gems" +description: "" +category: general +tags: [installation, gem] +--- +{% include JB/setup %} +The installation of opentox-webservices is straightforward with the `gem` command, e.g. + + gem install opentox-dataset + gem install toxbank-investigation + +This will install the webservice and all dependencies in your gem path. +Please do not forget to configure the webservice in `~/.opentox/config/<webservice>.rb`. +In some cases (eg. compound and algorithm) large external libraries have to be compiled - please be patient. |